# BASIC 256 - Language Documentation

en:onerror

## OnError

### Format

onerror label

### Description

Causes the Gosub at label to be executed or Subroutine to be called when an runtime error occurs. Program control may be resumed at the next statement with a Return statement in the subroutine.

### Example

See example of usage on Error Codes and ThrowError pages.

### See Also

Error Codes, Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror, ThrowError

### New To Version

0.9.6z

en/onerror.txt · Last modified: 2012/10/05 22:14 by admin