How to raise a event in a user-defined class module and handle this event by the same class module?
Hi! Everybody!
I meet a question. How i can raise a event in a user-defined class module and i want use one function to handle this event in the same class module? It means i want to event source and the event sink in the same class! How can i achieve it?
Thank you anybody's help!
Thank you very much!
Re: How to raise a event in a user-defined class module and handle this event by the same class modu
excerpt from the Visual Basic documentation (heading: "Adding Events to Classes"):
"Events cannot be handled within the class that declared them."
Re: How to raise a event in a user-defined class module and handle this event by the same class modu
Hi
VB doesn't allow you to raise errors and catch them in the same class.
- Couldn't you just call a private method in your class when you need to ?
Regards
Chris Eastwood
CodeGuru - the website for developers
http://www.codeguru.com/vb