PdfPasswordException Class

Thrown when an encrypted document is opened without its user or owner password (PdfReadOptions.Password), or, for a document encrypted for certificates, without the certificate of a recipient and its private key (PdfReadOptions.Certificate).

public sealed class PdfPasswordException : PdfException
Inheritance
PdfException PdfPasswordException

Constructors

NameDescription
PdfPasswordException()Initializes a new instance of the PdfPasswordException class.
PdfPasswordException(string?)Initializes a new instance of the PdfPasswordException class with a message.
PdfPasswordException(string?, Exception?)Initializes a new instance of the PdfPasswordException class with a message and the exception that caused it.

PdfPasswordException overloads

PdfPasswordException()

PdfPasswordException.cs

Initializes a new instance of the PdfPasswordException class.

public PdfPasswordException()

PdfPasswordException(string?)

PdfPasswordException.cs

Initializes a new instance of the PdfPasswordException class with a message.

public PdfPasswordException(string? message)
Parameters
message string?
The message that describes the error.

PdfPasswordException(string?, Exception?)

PdfPasswordException.cs

Initializes a new instance of the PdfPasswordException class with a message and the exception that caused it.

public PdfPasswordException(string? message, Exception? innerException)
Parameters
message string?
The message that describes the error.
innerException Exception?
The exception that caused the error.