BLOCK-LEVEL ON ERROR UNDO, THROW.
PROCEDURE find1000: /* Ignore potential errors */ FIND FIRST Customer WHERE CustNum = 1000 NO-ERROR. END PROCEDURE. PROCEDURE find2000: FIND FIRST Customer WHERE CustNum = 2000. CATCH eSysError AS Progress.Lang.SysError: /* Take care of this error locally */ END CATCH. END PROCEDURE. PROCEDURE find3000: FIND FIRST Customer WHERE CustNum = 3000. END PROCEDURE. /* Main Startup Procedure Block */ RUN find1000. RUN find2000. RUN find3000. /* Won't execute */ MESSAGE "Application completed execution successfully." VIEW-AS ALERT-BOX BUTTONS OK. CATCH eAnyError AS Progress.Lang.Error: MESSAGE "Unexpected error occurred..." SKIP "Logging information..." SKIP "Exiting application..." VIEW-AS ALERT-BOX BUTTONS OK. QUIT. END CATCH. |