Click or drag to resize

setDocumentSecurity Method

Sets the document security settings (user password, etc) for the current document in the PdfWebControl instance.

Syntax
JavaScript
function setDocumentSecurity(security);

Parameters

security

Type: PdfDocumentSecurity Class

a JavaScript object representing the desired document security settings.

Return Value

Type: Boolean

true if operation completed successfully; otherwise, false.

Examples
JavaScript
var myApi = new PdfWebControlApi("PdfWebControl1"); // where "PdfWebControl1" is the ID (ClientID) assigned to the PdfWebControl instance
myApi.setDocumentSecurity({"userPassword" : "my_password"}); //change the user password
See Also