[Mono-list] Howto: Build custom events

andrew Wilson a.wilson82 at gmail.com
Sat Sep 1 12:18:38 EDT 2007


To do this you want to read more about delegates.  I found just a few
articles real quick that do a good job showing you how they work.  The MSDN
article has some references to further reading.




On 9/1/07, Danny Stolle <dev.info at chello.nl> wrote:
> Hi all,
> this perhaps sounds really dumb, but i have some trouble writing events
> and raising them using C#. i have no trouble on writing classes having
> its methods, properties, etc. but when it comes to events, i don't know
> how to use them.
> programming in VB6, I used Microsoft back then, was easy. you declared
> the event you wanted, like: public event StatusOK(string message)
> within the class you could raise the event by using: RaiseEvent
> <eventname>: e.g. RaiseEvent StatusOK.
> Now I am off VB and using C#. But can somebody please point me out to
> some good documentation on how to write custom events for classes and
> how to raise them in your apps.
> Thanx a lot.
> Danny
> _______________________________________________
> Mono-list maillist  -  Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-list/attachments/20070901/e14c3c41/attachment-0001.html 

More information about the Mono-list mailing list