This example is designed put to use our simple error handling application, using the Revision 4 syntax, all users should have this in their applications as it is almost a must if your program couls generate errors, the simple code takes up only 5 lines of your application and will stop your users from getting nasty errors from your programs...

*I have nicely annotated the code for you

*Please note that you must have
Code:
ActivateObjects.True and
ObjectCreation.True
before any other code in your project...
Code:
CreateErrorHandler.True ++Creates the Error Handler Object
if(ErrorHandler returns *.True) then ++Starts the if...then statement of finding an error
halt() ++If an error is found, this halts your program
else ++Only here to complete an E++ If...then statement with no event for no error
endif ++Ends the if...then statement
Repeat(pr4,pr3,pr2,pr1).True and ++Repeats the 4 previous lines
define loopprevious(inf.) ++Loops the 4 previous lines constantly