ComWrappers.RegisterForMarshalling(ComWrappers) メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
ランタイムでマーシャリングするためのグローバル インスタンスとして使用する ComWrappers インスタンスを登録します。
public:
static void RegisterForMarshalling(System::Runtime::InteropServices::ComWrappers ^ instance);
public static void RegisterForMarshalling (System.Runtime.InteropServices.ComWrappers instance);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public static void RegisterForMarshalling (System.Runtime.InteropServices.ComWrappers instance);
static member RegisterForMarshalling : System.Runtime.InteropServices.ComWrappers -> unit
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
static member RegisterForMarshalling : System.Runtime.InteropServices.ComWrappers -> unit
Public Shared Sub RegisterForMarshalling (instance As ComWrappers)
パラメーター
- instance
- ComWrappers
登録するインスタンス。
- 属性
例外
メソッドは複数回呼び出されました。
注釈
この関数は、1 回のみ呼び出すことができます。 この関数を後続で呼び出すと InvalidOperationException 、スローされます。 このグローバル インスタンスを使用できるシナリオは次のとおりです。 * COM 関連のマーシャリング API の使用 * COM 関連の型を使用した P/Invokes * COM のアクティブ化