OPC Studio User's Guide and Reference
LoadCertificate Method (_X509CertificateTokenInfo)



OpcLabs.BaseLib Assembly > OpcLabs.BaseLib.IdentityModel.User.ComTypes Namespace > _X509CertificateTokenInfo Interface : LoadCertificate Method
Loads an X.509 certificate from the information configured in the token info.
Syntax
'Declaration
 
<NotNullAttribute()>
Function LoadCertificate() As ValueResult
'Usage
 
Dim instance As _X509CertificateTokenInfo
Dim value As ValueResult
 
value = instance.LoadCertificate()
[NotNull()]
ValueResult LoadCertificate()
[NotNull()]
ValueResult^ LoadCertificate(); 

Return Value

Returns the value result with the certificate loaded, based on this X.509 certificate token info.

This method never returns null (Nothing in Visual Basic).

Exceptions
ExceptionDescription

An error occurred during a cryptographic operation.

This is an operation error that depends on factors external to your program, and thus cannot be always avoided. Your code must handle it appropriately.

A method call was invalid for the object's current state.

This is a usage error, i.e. it will never occur (the exception will not be thrown) in a correctly written program. Your code should not catch this exception.

Remarks

This member or type is for use from COM. It is not meant to be used from .NET or Python. Refer to the corresponding .NET member or type instead, if you are developing in .NET or Python.

Requirements

Target Platforms: .NET Framework: Windows 10 (selected versions), Windows 11 (selected versions), Windows Server 2016, Windows Server 2022; .NET: Linux, macOS, Microsoft Windows

See Also