THotPDF.ActivateProtection Property

 

THotPDF.ActivateProtection

THotPDF

 

Вверх  Назад  Далее

Determines whether the PDF document is encrypted.

 

Delphi syntax:

property ActivateProtection: Boolean;

 

C++ syntax:

__property bool ActivateProtection;

 

Описание

A PDF document can be encrypted to protect its contents from unauthorized access. Set ActivateProtection to true to enable PDF encryption or Set ActivateProtection to false to disable PDF encryption.

Значение по умолчанию: false (opt-in; сохраняет textual xref table для tooling, которое hard-codes keyword xref, и для максимальной совместимости с PDF 1.4 / earlier readers)

 

Code Example

HPDF.OwnerPassword := 'password';          // Set owner password (required to change security settings)
HPDF.UserPassword := 'user';               // Set user password (required to open the document)
HPDF.ProtectOptions := [poEdit, poAnnot];  // Disallow editing and annotations
HPDF.ActivateProtection := true;           // Enable PDF security

 

См. также: CryptKeyLength, OwnerPassword, ProtectOptions, UserPassword