Marshal.GetExceptionForHR Method

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Converts an HRESULT error code to a corresponding Exception object.

Namespace:   System.Runtime.InteropServices
Assembly:  mscorlib (in mscorlib.dll)

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticGetExceptionForHR(Int32)

Converts the specified HRESULT error code to a corresponding Exception object.

System_CAPS_pubmethodSystem_CAPS_staticGetExceptionForHR(Int32, IntPtr)

Converts the specified HRESULT error code to a corresponding Exception object, with additional error information passed in an IErrorInfo interface for the exception object.

Return to top
Show: