Return to the Home Page...
Features on BBC BASIC programming...
Your questions and answers...
Buy or Sell an NC...
The NC200 manual and data sheets for BBC BASIC...
Information about BBC BASIC on the NC...
Free software for you to download...

Tim's Amstrad NC Users' Site

BBC BASIC Error Messages Data Sheet

The table below shows the error messages generated by the BASIC interpreter and their corresponding error codes.
When using ONERROR to trap errors, it can be useful to include the following which will inform you of any error that you have not allowed for. This will show the error in the format error at line line.

REPORT:PRINT;" at line ";ERL

ERR code Error message Likely explanation
1 Out of range ???
4 Mistake Probably a typing error such as a command in lower case
5 Missing , A parameter has been left out of a command
6 Type mismatch You have used a string instead of a number as a command's parameter or vice-versa
7 No FN BASIC has met a DEF FN statement but you have not called the FN
9 Missing " One of the quotes has been missed out of a statement
10 Bad DIM The array you have tried to DIM has already been defined. Put DIM's right at the start of a program
11 DIM space There is not enough memory for the array to be defined
12 Not LOCAL The variable you have used in a PROC or FN is used elsewhere in the program
13 No PROC BASIC has met a DEF PROC statement but you have not called the PROC
14 Array The array has not been defined by a DIM statement
15 Subscript You have addressed a cell in the array that does not exist
16 Syntax error You are using a command incorrectly
17 Escape The STOP key has been pressed
18 Division by zero You have divided a number by 0, which equals infinity!
19 String to long There are too many characters in the string and they can't all be stored
20 Too big The number is too large to be stored
21 -ve root You have tried to SQT a negative number
22 Log range A log cannot be taken of the number
23 Accuracy lost The result of the mathematical function is no longer accurate
24 Exp range The exponent is too large
26 No such variable The variable has not been defined
27 Missing ) The number of opening and closing brackets does not match
28 Bad HEX The hexadecimal number is invalid.  Valid characters are 0 to 9 and A to F
29 No such FN/PROC The FN or PROC you called has not been DEFined
30 Bad call The machine code routine does not exist
31 Arguments The number of parameters supplied to a FN or PROC is not the same as the number defined in the DEFinition
32 No FOR You have used a NEXT to end a loop which was not begun
33 Can't match FOR The loops are not nested correctly - you may have jumped out of a loop.
34 FOR variable You have left out the loop variable in a FOR statement
36 No TO You have left out the TO in a FOR statement
38 No GOSUB RETURN has been found, but no GOSUB was called
39 ON syntax The wrong commands have been used with the ON command
40 ON range The number supplied to an ON statement exceeds the number of branches supplied
41 No such line The line number in a GOTO, GOSUB or ON does not exist
42 Out of DATA There is no data in any DATA lines left to READ
43 No REPEAT UNTIL has been found when there has been no REPEAT
45 Missing # In filing commands the # has been left out
255 Sorry The command is not supported on the NC - examples are MODE, COLOR, *FX, INKEY(-x)
 
© 1997 – 2024 Tim Surtell

Tim's Amstrad NC Users' Site
www.ncus.org.uk