संपादित करें

इसके माध्यम से साझा किया गया


EventDescriptor.RemoveEventHandler(Object, Delegate) Method

Definition

When overridden in a derived class, unbinds the delegate from the component so that the delegate will no longer receive events from the component.

public:
 abstract void RemoveEventHandler(System::Object ^ component, Delegate ^ value);
public abstract void RemoveEventHandler (object component, Delegate value);
abstract member RemoveEventHandler : obj * Delegate -> unit
Public MustOverride Sub RemoveEventHandler (component As Object, value As Delegate)

Parameters

component
Object

The component that the delegate is bound to.

value
Delegate

The delegate to unbind from the component.

Remarks

Typically, this method is implemented through reflection. For more information, see the topics in Reflection.

For more information about delegates, see Handling and Raising Events.

Notes to Implementers

When you override this method, it should remove the delegate from the component's event list by invoking the appropriate remove_myHandler method.

Applies to

See also