21.5. Error codes
When an error happens the error code can be retrieved using the function ERROR() in the error handling code. This value is an integer value. To compare this value against a specific error code the program should include the file `error.bas'. This file defines global constants for each run time error. It is advised to use these symbolic constants because there is no guarantee that the actual value of an error code remains the same between builds. The file `error.bas' is generated automatically when the interpreter C language constants are generated. The file also contains the English language explanation of each error following the line that defines the global constant for the error code.