Doc.setPassword

Sets a password for the document. If the password is set, document contents are encrypted

class Doc
HPDF_STATUS
setPassword
(,
string userPasswd = null
)

Parameters

ownerPasswd string

The password for the owner of the document. The owner can change the permission of the document. null, zero length string, and the same value as user password are not allowed.

userPasswd string

The password for the user of the document. The userPassword may be set to null or zero length string.

Meta