Home All Groups Group Topic Archive Search About

Raising Events in Modules?

Author
25 May 2006 3:00 PM
Amjad
Hello,

I have a main Windows Form and a Module class in a Solution. I'd like to
know if a Timer.Tick event for example get raised in the Module when I'm
running the Windows Form?

The same thing can be asked when I'm using the SerialPort control in the
module; I want to know if the SerialPort.DataReceived event can get raised
when serial data is received?

If that's possible could someone place some code on how to do so?

Thanks.

Author
25 May 2006 5:24 PM
Michel Posseth [MCP]
A module is internally nothing else as a class with all methods declared as
shared

you can also declare shared events however catching the event in a form
requires you to set a handler for it

i hope i am clear enough with my explanation :-)

regards

Michel Posseth [MCP]



Show quoteHide quote
"Amjad" <Am***@discussions.microsoft.com> schreef in bericht
news:CCDD801D-E97A-4E79-8CD7-3C511E3627D4@microsoft.com...
> Hello,
>
> I have a main Windows Form and a Module class in a Solution. I'd like to
> know if a Timer.Tick event for example get raised in the Module when I'm
> running the Windows Form?
>
> The same thing can be asked when I'm using the SerialPort control in the
> module; I want to know if the SerialPort.DataReceived event can get raised
> when serial data is received?
>
> If that's possible could someone place some code on how to do so?
>
> Thanks.