SyntaxAddHandler nameOfEventSender, AddressOf nameOfEventHandler
DescriptionThe AddHandler statement binds an event handler to an event. Usage at a GlanceThe AddHandler and RemoveHandler statements can be used to dynamically add and remove event-notification handlers at runtime. By contrast, the Handles keyword establishes an event-notification handler at compile time. ExampleChapter 8 includes examples of using event handlers. Version DifferencesVisual Basic 2005 includes a new Custom Events statement that impacts the use of the AddHandler statement. See the Custom Event Statement entry in this chapter for additional information. See AlsoCustom Event Statement, RemoveHandler Statement |