Marshal.GetExceptionCode 方法

定义

注意

GetExceptionCode() may be unavailable in future releases.

检索标识所发生异常的类型的代码。

public:
 static int GetExceptionCode();
[System.Obsolete("GetExceptionCode() may be unavailable in future releases.")]
[System.Security.SecurityCritical]
public static int GetExceptionCode ();
[System.Obsolete("GetExceptionCode() may be unavailable in future releases.")]
public static int GetExceptionCode ();
public static int GetExceptionCode ();
[System.Security.SecurityCritical]
public static int GetExceptionCode ();
[<System.Obsolete("GetExceptionCode() may be unavailable in future releases.")>]
[<System.Security.SecurityCritical>]
static member GetExceptionCode : unit -> int
[<System.Obsolete("GetExceptionCode() may be unavailable in future releases.")>]
static member GetExceptionCode : unit -> int
static member GetExceptionCode : unit -> int
[<System.Security.SecurityCritical>]
static member GetExceptionCode : unit -> int
Public Shared Function GetExceptionCode () As Integer

返回

异常的类型。

属性

注解

GetExceptionCode 公开是为了编译器仅支持 SEH) (结构化异常处理。 如果在引发异常之前调用此方法,它将返回0x0。

适用于