ComWrappers.RegisterForMarshalling(ComWrappers) メソッド

定義

ランタイムでマーシャリングするためのグローバル インスタンスとして使用する 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 の使用 * P/COM 関連の型を使用した呼び出し * COM のアクティブ化

適用対象