PdfSaveOptions.EncryptionHandler Property

Gets or sets the encryption handler to use while encrypting the output PDF.

Namespace:  BitMiracle.Docotic.Pdf
Assembly:  BitMiracle.Docotic.Pdf (in BitMiracle.Docotic.Pdf.dll)

Syntax

C#
public PdfEncryptionHandler EncryptionHandler { get; set; }
VB
Public Property EncryptionHandler As PdfEncryptionHandler
	Get
	Set

Property Value

Type: PdfEncryptionHandler
The encryption handler to use while encrypting the output PDF.

Remarks

Default value: null.

If this property is null then the output document will not be encrypted.

Set this property to an instance of PdfStandardEncryptionHandler to to protect the output document with password(s).

Set this property to an instance of PdfPublicKeyEncryptionHandler to to protect the output document with certificate(s).

PDF/A documents can not be encrypted. Therefore, an exception will be thrown if you try to use an encryption handler when ProducePdfA is true.

See Also