Error handler just goes away! Why?
Doug Easterbrook
doug at artsman.com
Thu Mar 19 10:57:03 EDT 2015
I suspect it goes away because you clear the method stack. I've seen that.
what we do at the end of the error handler is the following two commands. I recall having to do that eons ago to keep the handler alive and I don't recall where I read it.
Calculate #F as 0
SEA continue execution
so. you could, if its an error on the polling window...... set a flag in your error routine that tells it to stop and start itself.
I have also found that if you have a breakpoint in the error handler, and go up in the debugger to he method that called the error handler and continue execution from there, your error handler will not get called again. Kind of like what you say.
the only way I've found for it to keep on going it to make sure it ends nicely with the above two commands.
eg errorhanlder
do my stuff and set flags
Calculate #F as 0
SEA continue execution
and the error handler will work for the next error condition. if you don't finish the method, it will not get called again until you restart omnis.
It might work if you clear the error handlers and reset them.. but I can't vouch for that.
Doug Easterbrook
Arts Management Systems Ltd.
mailto:doug at artsman.com
http://www.artsman.com
Phone (403) 536-1205 Fax (403) 536-1210
> On Mar 19, 2015, at 8:35 AM, David Barnett <david at fairlibertyscall.com> wrote:
>
> In this case, I'm working in Studio 5.1.1.
>
> Situation: there's a 'polling' window with a timer running to check a table periodically for event records to process. That's all fine. But at some locations an export triggered by one of those events hits a disk error now and then, which raises a specific Omnis error. That gets trapped in an error handler so we can log the error.
>
> In the error handler I call 'clear method stack', close the polling window, write out some additional error log records, and re-open the polling window. That re-establishes the polling action just fine. But at that point the error handle is gone, lost at sea, absolutely nowhere to be found. I can't even reestablish it with a new set error handler call. I have to close Omnis and restart the app. The error handler gets set at startup and works fine.
>
> So, why does it just go away for no apparent reason? And why can't I reset it? Any ideas?
>
> David
>
> David Barnett David at FairLibertysCall.com
> C: 516-398-8668 www.FairLibertysCall.com
>
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com
More information about the omnisdev-en
mailing list