Error processing SSI file
LEADTOOLS PDF (Leadtools.Pdf assembly)

Show in webframe

UserPassword Property






The user password to use when encrypting a PDF file.
Syntax
public string UserPassword {get; set;}
'Declaration
 
Public Property UserPassword As String
'Usage
 
Dim instance As PDFSecurityOptions
Dim value As String
 
instance.UserPassword = value
 
value = instance.UserPassword
public:
property String^ UserPassword {
   String^ get();
   void set (    String^ value);
}

Property Value

A System.String that contain the user password to use when encrypting a PDF file. The default value is null.
Remarks

PDF files can be encrypted with two passwords: user (UserPassword and owner OwnerPassword.

The UserPassword is used only with viewing the PDF file, so PDF viewers such as Adobe Acrobat will ask for the UserPassword if specified in a PDF and will allow anyone to view the file if a correct value is supplied. To allow anyone to view the PDF file, do not set a value in the UserPassword (leave it as an empty string or null).

The OwnerPassword is used to restrict certain rights on the PDF file when loading into a view such as Adobe Acrobat, these include disabling print (PrintEnabled and HighQualityPrintEnabled), copying text to the clipboard (CopyEnabled), annotations (AnnotationsEnabled) and editing and re-assembling the PDF file (EditEnabled and AssemblyEnabled). When encrypting a PDF file with an OwnerPassword, you can enable or disable any of these rights based on your application needs.

You cannot supply both a user and owner password in the same PDF file. If both passwords are supplied, then the UserPassword is ignored.

Example

For an example, refer to PDFFile.

Requirements

Target Platforms

See Also

Reference

PDFSecurityOptions Class
PDFSecurityOptions Members

Error processing SSI file
   Leadtools.Pdf requires a PDF Pro, Pro Suite, Document, or Medical license and unlock key. For more information, refer to: LEADTOOLS Toolkit Features