Share via


ComWrappers.RegisterForTrackerSupport(ComWrappers) 方法

定义

注册具有以下用途的 ComWrappers 实例:用作引用跟踪器支持的全局实例。

public:
 static void RegisterForTrackerSupport(System::Runtime::InteropServices::ComWrappers ^ instance);
public static void RegisterForTrackerSupport (System.Runtime.InteropServices.ComWrappers instance);
static member RegisterForTrackerSupport : System.Runtime.InteropServices.ComWrappers -> unit
Public Shared Sub RegisterForTrackerSupport (instance As ComWrappers)

参数

instance
ComWrappers

要注册的实例。

例外

该方法被调用了多次。

注解

此函数只能调用一次。 对此函数的后续调用将导致 InvalidOperationException 引发 。 可以使用此全局实例的方案包括:* 通过 TrackerSupportTrackerObject 标志跟踪对象。

适用于