Errors And Warnings

HUNTER’S Basic Interpreter will display one of a number of messages on an error occurring.

The messages have three characters, generally with a line number. The meaning may be found with reference to the following table. They are aimed at experienced programmers.

Each error has an error number. This is the value returned by the ERR verb and is useful during error trapping.

Message

No.

Meaning

ARG

0

ARGUMENT ERROR: A function has been called with an out of range argument.

STX

1

SYNTAX ERROR: Incorrect syntax in a Basic statement.

CSK

2

CONTROL STACK ERROR: Incorrect F0R…NEXT; WHILE…WEND or GOSUB…RETURN construction.

SSK

3

SYSTEM STACK ERROR: Attempt to POP a nonexistent variable.

DIN

4

DIRECT INPUT ERROR: Use of a meaningless Basic statement as a command, e.g. NEXT.

DIM

5

DIMENSION ERROR: Attempt to redefine an existing variable.

FP

6

FLOATING POINT ERROR: Illegal maths operation, e.g. B=A/C where C=0.

LNo

7

LINE NUMBER ERROR: Reference to a nonexistent line number.

SQR

8

NEGATIVE SQUARE ROOT:

MAC

9

MAGNITUDE ERROR: Reference to an array element larger than the array dimension.

RD

10

READ ERROR: The data statement is either invalid or non-existent.

MEM

11

STORAGE OVERFLOW: Variable storage or array overflowed available memory.

ARY

12

ARRAY ERROR: Use of an element in an undefined array.

BAS

13

BASIC SOURCE ERROR: Attempt to run a non-Basic program.

HLP

14

HELP SOURCE ERROR: The HELP statement has an Illegal line number reference.

TYP

15

TYPE MISMATCH ERROR: Received string data type instead of numeric.

STR

16

STRING COMPLEX ERROR: Insufficient space to manipulate a string expression.

RES

17

RESUME WITHOUT ERROR:

FNF

18

FILE NOT FOUND: Reference to a non-existent file.

IFN

19

ILLEGAL FILE NAME: Filename does not conform to standards of file names.

FOP

20

FILE ALREADY OPEN:

FNO

21

FILE NUMBER ERROR: File number greater than MAXFILE.

FCL

22

FILE CLOSED ERROR:

FOO

23

FILE OPEN FOR OUTPUT ERROR:

FOI

24

FILE OPEN FOR INPUT ERROR:

WWD

25

WHILE/WEND ERROR: WHILE without WEND or WEND without WHILE.

DSK

26

DISK ACCESS ERROR:

???

27-255

USER DEFINED ERROR: