For even more information :), try
http://www.levelextreme.com/magazine/june2003/page28.asp>More information about it...
>--- Structured Error Handling in VFP 8 ---
>--- by Markus Egger.
>
http://www.code-magazine.com/focus/Article.aspx?quickid=0301072>
>
>I have just started using these and have to say I love them! What a great thing to add to the language. Why to go!
>
>No more
>>lc_error = SET('ERROR')
>ll_error = .f.
>ON ERROR ll_error = .t.
>*do something that might cause an error
>IF ll_error
> * clean up
>ENDIF
>
>ON ERROR &lc_error.
>
>Now it's
>
>TRY
> * do something that might cause an error
>CATCH
> * clean up
>ENDTRY
>
Hector Correa