If you are using "shell" to run the other program, it sets the error level to that of the called program. That is, if you shell out and run xyz.exe, and then test @ERROR on the next line, the value will be set to the exit value for xyz.exe. Hope that helps.

code:

Shell "C:\program files\xyz.exe"
If @ERROR=0
? "The program ran with no problems!"
Else
? "There were errors encountered with xyz!"
Endif

------------------
Regards,

Brad
Consultant
Net InfraStructure, Inc