Geeks With Blogs
Dheeman Dutta Just Another Blog..... February 2007 Entries
Generic EventHandler a new way of handling events
I was surprised to see the syntax of the new Generic Eventhandler... Using the .net 1.1 way we can declare events using the following steps.. STEP 1: declare a delegate public delegate void DivThreeHandler(object ,DivByThreeEventArgs e); The abobe delegate declares the parameters to be sent to the event handlers.Any class that wants to handle this event needs to have a method that mathces this signature. STEP 2: define the EventArgs derived class public class DivByThreeEventArgs:EvetArgs{ ...........code.......} ......

Posted On Thursday, February 15, 2007 7:17 AM

Copyright © Dheeman Dutta | Powered by: