Thank you for your answer. I meant that the controls would throw the exceptions and they would be handled by the window. At this time we are in the normal message loop. So the question is really in two parts.
1) Can I catch these exceptions on the form
2) Am I really using an exception as a signalling device, and in .Net you should approach it diffferently
What I am really trying to achieve is to send a event / dynamic call to a parent form and or control, not caring if the controls knows what it is. For example MyWonderfulButton class may send a 'signal' to every control between itself up to and including the form that is has been enabled. MyWonderfulButton neither knows nor cares what action they take. This was quite normal in my previous environment (Powerbuilder) where these signals took the form of custom events. If any control didn't handle it then there is no problem. The event also trickled through all the inherited layers of any intermediate control.
<aside>
Each language / environment seems to have its own words..
Classes: Descendant, Ancester, Parent , Derived , superclass, subclass, inherited class,
Events: Handle, Consume, Trigger, Post, Send, Process
I must get the right vernacular for the Netis
</aside>
|