Uredi

Deli z drugimi prek


EventBindingService.UseMethod(IComponent, EventDescriptor, String) Method

Definition

Provides a notification that a particular method is being used by an event handler.

protected:
 virtual void UseMethod(System::ComponentModel::IComponent ^ component, System::ComponentModel::EventDescriptor ^ e, System::String ^ methodName);
protected virtual void UseMethod (System.ComponentModel.IComponent component, System.ComponentModel.EventDescriptor e, string methodName);
abstract member UseMethod : System.ComponentModel.IComponent * System.ComponentModel.EventDescriptor * string -> unit
override this.UseMethod : System.ComponentModel.IComponent * System.ComponentModel.EventDescriptor * string -> unit
Protected Overridable Sub UseMethod (component As IComponent, e As EventDescriptor, methodName As String)

Parameters

component
IComponent

The component to which the method is bound.

e
EventDescriptor

The EventDescriptor for the event handler.

methodName
String

The name of the method.

Remarks

Some implementations may intend to remove the event handler when no events are using it. By overriding UseMethod and FreeMethod, an implementation can infer when a method is no longer needed.

Applies to

See also