Share via


ToString Method

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

Displays an X.509 certificate in text format.

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

Syntax

'Declaration
Public Overrides Function ToString As String
public override string ToString()
public:
virtual String^ ToString() override
abstract ToString : unit -> string 
override ToString : unit -> string 
public override function ToString() : String

Return Value

Type: System. . :: . .String
The certificate information.

Remarks

As with all ToString methods, the output might not be consistent across versions of the .NET Framework, so the method results should not be parsed for content. Use the properties on the X509Certificate2 object to obtain precise information about the content or use the ToString method to obtain information about the certificate.

This method displays the certificate in text format.

.NET Framework Security

See Also

Reference

X509Certificate2 Class

ToString Overload

System.Security.Cryptography.X509Certificates Namespace