Document Solutions for PDF
GrapeCity.Documents.Pdf Assembly / GrapeCity.Documents.Pdf.Security Namespace / StandardSecurityHandler Class / HasOwnerPassword Property

In This Topic
    HasOwnerPassword Property
    In This Topic
    Gets a value indicating whether the PDF has an owner password that is required to edit the document.

    This property is initialized when the document is loaded.

    Note that a document may be encrypted with an empty password, in which case HasUserPassword and HasOwnerPassword properties return false.

    Note also that, according to the PDF specification, if an owner password is not specified, then the user password should be used. GcPdf follows this rule, so if a PDF that was created using GcPdf with only a user password is loaded into GrapeCity.Documents.Pdf.GcPdfDocument, its AccessType will be AccessType.Owner, HasOwnerPassword will be true and HasUserPassword will also be true.
    Syntax
    'Declaration
     
    Public ReadOnly Property HasOwnerPassword As System.Nullable(Of Boolean)
    public System.Nullable<bool> HasOwnerPassword {get;}
    See Also