OleDbInfoMessageEventArgs.ErrorCode 属性

定义

获取符合数据库 ANSI SQL 标准的 HRESULT。Gets the HRESULT following the ANSI SQL standard for the database.

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

属性值

Int32

HRESULT,如果错误可能源自不止一个地方,则它识别错误的来源。The HRESULT, which identifies the source of the error, if the error can be issued from more than one place.

注解

这是 SQLState 集合中第一个的属性的包装 OleDbError ErrorsThis is a wrapper for the SQLState property of the first OleDbError in the Errors collection.

适用于