Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to trap errors with ON ERROR while error event in pl
Message
From
13/02/2002 04:16:54
 
 
To
13/02/2002 04:05:20
Walter Meester
HoogkarspelNetherlands
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00618670
Message ID:
00619316
Views:
18
Walter,

This shouldn't be a problem. If you look at Doug's code, it checks if there's already an error handler. If yes, he simply calls the active error handler with the correct parameters. In your case, the trigger's ON ERROR statement will be called and everything should work as expected.

HTH
>David,
>
>PMFJI, but there is one thing people should be aware off. The RI mechanism in the standard VFP RIBuilder (and my TaxRiBuilder for that matter) rely on the ON ERROR mechanism.
>
>If in an object with code in the error event triggers the RI code in the database, you'll have to handle the cases that error event fires because of errors in the RI procedure. I think this also has been pointed out by doug hennig in one of its articles on his website.
>
>Therefore I tend to use error events only in cases where absolutely needed and there where there is no chance of intermixing it with the ON ERROR handler.
>
>Walter,
>
>>I'm sorry, but there's nothing unfortunate about an object being fully in control of any errors that occur within the code of the object itself. That is the way things should be in a good object-oriented language.
>>
>>>As you already figured out, there is no way and that's unfortunate. I was caught by this behavior couple of times... I'm not sure, we can wish about it for Toledo, because adding ability to switch will break the existing code...
Daniel
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform