System.Security.Cryptography.X509Certificates.X509Certificate.Import Method

Populates the System.Security.Cryptography.X509Certificates.X509Certificate object with information from a certificate file.

Syntax

[System.Runtime.InteropServices.ComVisible(false)]
public virtual void Import (string fileName)

Parameters

fileName
The name of a certificate file represented as a string.

Remarks

This method uses a certificate file (such as a file with a .cer extension) that represents an X.509 certificate, and populates the System.Security.Cryptography.X509Certificates.X509Certificate object with the certificate that the file contains.

Requirements

Namespace: System.Security.Cryptography.X509Certificates
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0
Since: .NET 2.0