Windows apps
Collapse the table of content
Expand the table of content

NotAfter Property

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Gets the date in local time after which a certificate is no longer valid.

Namespace:  System.Security.Cryptography.X509Certificates
Assembly:  System.Security (in System.Security.dll)

public:
property DateTime NotAfter {
	DateTime get ();
}

Property Value

Type: System..::..DateTime
A DateTime object that represents the expiration date for the certificate .

ExceptionCondition
CryptographicException

The certificate is unreadable.

This property indicates an expiration date on which the certificate becomes invalid.

Show:
© 2017 Microsoft