Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error Event in a form
Message
 
 
À
02/05/2001 17:52:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00502795
Message ID:
00502854
Vues:
18
Hi Stephane,

See this forum http://www.ideaxchg.com/ix07/er/_sys/toccontu.htm for the Error Handler documentation.



>Hi,
>
>Is it possible, like with the "ON ERROR" command, to redefine or re-direct the Error Event of a form? Here's why: I'm trying to open a table in 'exclusive' mode inside an object and I don't want any error messages or anything like that if it fails. I'd like to convert this piece of code to work inside my object:
>
>LOCAL lcOldError, lnError
>lcOldError = ON("ERROR")
>ON ERROR lnError = ERROR()
>USE lcTablePath IN 0 EXCLUSIVE
>ON ERROR &lcOldError
>IF VARTYPE(lnError) == "L" THEN
> RETURN .T.
>ELSE
> RETURN .F.
>ENDIF
>

>Is it possible?
>
>Thanks a lot in advance, Stephane.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform