ERROR( ) Function

Example   See Also

Returns the error number for the error that triggered an ON ERROR routine.

Syntax

ERROR( )

Returns

Numeric

Remarks

ERROR( ) returns the number of the most recent error. An ON ERROR routine must be active for ERROR( ) to return a value other than 0.

When an error is trapped during program execution, the error type can be returned by ERROR( ) in an ON ERROR routine. The corresponding error message can be returned by MESSAGE( ).

The value ERROR( ) returns is reset by RETURN or RETRY.