EventRegistrationTokenTable<T>.AddEventHandler(T) 方法

定义

添加指定的事件处理程序到该表和调用列表,并返回可用于移除该事件处理程序的标志。

public:
 System::Runtime::InteropServices::WindowsRuntime::EventRegistrationToken AddEventHandler(T handler);
public System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken AddEventHandler (T handler);
public System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken AddEventHandler (T? handler);
member this.AddEventHandler : 'T -> System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken
Public Function AddEventHandler (handler As T) As EventRegistrationToken

参数

handler
T

要添加的事件处理程序。

返回

可用于将事件处理程序从表和调用列表中移除的标志。

适用于