Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
On Error .... with THIS
Message
De
24/07/2002 14:07:59
 
 
À
24/07/2002 13:34:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00682154
Message ID:
00682177
Vues:
16
>Is there any way to "On Error Do myErrorHandler with THIS"?
>I've tried "... with iif(type('THIS')='O',THIS,.F.)", but I never receive an Object in myErrorHandler.

You could also put error handling logic in the Error event of the class. Something like:
procedure Error(tnError, tcMethod, tnLine)

* If I can't handle this error at the class level, pass it to a global error handler
if NOT this.HandleError(tnError, tcMethod, tnLine)
     MyErrorHandler(this, tnError, tcMethod, tnLine)
endif
endproc
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform