PrincipalOperationException.ErrorCode 属性

定义

返回整数错误代码。Returns an integer error code.

public:
 property int ErrorCode { int get(); };
public int ErrorCode { get; }
member this.ErrorCode : int
Public ReadOnly Property ErrorCode As Integer

属性值

整数错误代码。An integer error code. 如果收到来自 win32 API 的基础错误,系统将在异常错误代码属性中返回 0(零)。The system will return 0 (zero) in the exception error code property if no underlying error was received from a win32 API. 调用方需要区分 0(零)和有效的 win32 错误代码。Callers need to distinguish between 0 (zero) and a valid win32 error code.

适用于