Initializes a new instance of the EventDescriptorCollection class.
[Visual Basic] Public Sub New( _ ByVal events() As EventDescriptor _ ) [C#] public EventDescriptorCollection( EventDescriptor[] events ); [C++] public: EventDescriptorCollection( EventDescriptor* events[] ); [JScript] public function EventDescriptorCollection( events : EventDescriptor[] );
If events is empty, this constructor creates an empty EventDescriptorCollection.
The following example creates a new EventDescriptorCollection using the events on Button1. It assumes that Button1 has been instantiated on a form.
[Visual Basic]
Dim events As EventDescriptorCollection events = TypeDescriptor.GetEvents(Button1)
EventDescriptorCollection Class | EventDescriptorCollection Members | System.ComponentModel Namespace | EventDescriptor | TypeDescriptor