ErrorWrapper Class
TOC
Collapse the table of content
Expand the table of content

ErrorWrapper Class

Wraps objects the marshaler should marshal as a VT_ERROR.

For a list of all members of this type, see ErrorWrapper Members.

System.Object
   System.Runtime.InteropServices.ErrorWrapper

[Visual Basic]
NotInheritable Public Class ErrorWrapper
[C#]
public sealed class ErrorWrapper
[C++]
public __gc __sealed class ErrorWrapper
[JScript]
public class ErrorWrapper

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Remarks

By default, Object type arguments are marshaled as a VARIANT type, where the object type determines the VARTYPE value of the VARIANT. For example, an integer type passed as Object is marshaled as a VT_I4. In order to marshal the integer as a variant of type VT_ERROR, the integer can be wrapped in the ErrorWrapper before making the method call.

For more information on VT_ERROR, please see the existing documentation for VARENUM::VT_ERROR in the MSDN library.

Requirements

Namespace: System.Runtime.InteropServices

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

Assembly: Mscorlib (in Mscorlib.dll)

See Also

ErrorWrapper Members | System.Runtime.InteropServices Namespace

Show:
© 2016 Microsoft