General information
Category:
Coding, syntax & commands
>WHat is your exact code?
Well, I've got it working now. What I _was_ doing in a form Valid() method:
...
THISFORM.llUseError=.F.
USE mytable EXCLU ALIAS xxdummy
IF !THISFORM.llUseError
do stuff
ELSE
alert user
ENDIF
...
and in the FORM's Error() method:
IF nError=3
THISFORM.llUseError=.T.
ELSE
=DODEFAULT() &&my error handler.
ENDIF
*=============*
When I do it directly in the method, as you suggested, this works:
jcOldErr=ON("ERROR")
jlError=.F.
ON ERROR jlError=.T.
USE mytable EXCLU ALIAS xxdummy
IF !jlError
do stuff
ELSE
alert user
ENDIF
ON ERROR &jcOldErr
*=============*
Don't know why the first doesn't work...
Thanks, Mike.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only