Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Custom Marshaling

A custom marshaler enables you to precisely control the way in which a managed type is exposed to COM or an unmanaged type is exposed to the .NET Framework. You use a custom marshaler instead of the interop marshaler, which the common language runtime provides by default.

Custom Marshaling Overview

Describes the custom marshalers at a high level.

Defining the Marshaling Type

Describes how to prepare the interfaces involved in setting up a custom marshaler.

Implementing the ICustomMarshaler Interface

Describes the options in preparing a custom marshaler.

Using a Substitute Marshaler

Describes how to use the MarshalAsAttribute attribute to insert a custom marshaler.

Interop Marshaling

Describes marshaling for COM interop and platform invoke.

Community Additions

ADD
Show:
© 2015 Microsoft