BCL easyPDF SDK
easyPDF SDK Usermanual
PDF Creator Programming API  |  Download Free Trial  |  Contact Us to Purchase

HasUserPassword Method

Checks if a PDF file has a password.

Function HasUserPassword(InputFileName As String) As Boolean

bool HasUserPassword(string InputFileName)

boolean HasUserPassword(String InputFileName) throws PDFProcessorException

Parameters

Return Values

True if the given PDF file has a user password; False otherwise.

Remarks

N/A.

Example Usage

Set oProcessor = CreateObject("easyPDF.PDFProcessor.8")
bProtected = oProcessor.HasUserPassword("C:\test\input.pdf")
If bProtected Then
    MsgBox "This file has an user password."
End If