Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

EventDescriptor::AddEventHandler Method (Object^, Delegate^)

 

When overridden in a derived class, binds the event to the component.

Namespace:   System.ComponentModel
Assembly:  System (in System.dll)

public:
virtual void AddEventHandler(
	Object^ component,
	Delegate^ value
) abstract

Parameters

component
Type: System::Object^

A component that provides events to the delegate.

value
Type: System::Delegate^

A delegate that represents the method that handles the event.

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

For more information about delegates, see NIB: Events and Delegates.

Notes to Inheritors:

When you override this method, it should add the delegate to the component's event list by invoking the appropriate add_myHandler method.

.NET Framework
Available since 1.1
Return to top
Show:
© 2017 Microsoft