O'Reilly logo

Microsoft® Visual Basic® 2010 Developer’s Handbook by Klaus Löffelmann and Sarika Calla Purohit

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Implementing Your Own Event Handlers

In some cases, it’s important for you to have complete control over event registration and triggering—especially for debugging purposes.

Suppose that you have developed a complex component, and you need to check which of its instances consume a certain event and how long the execution of this event takes. This can be tricky, because the component “knows” that it raises an event, but you can’t formulate the code in such a way that you are informed as to what event handlers are wired into your component.

Using custom event handlers, this is now possible. It’s also worth mentioning that custom event handlers were available in Visual Studio 2008, but they weren’t documented anywhere! A custom event handler defines ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required