Omron C200H-ASC11 Manual page 165

Ascii units
Hide thumbs Also See for C200H-ASC11:
Table of Contents

Advertisement

Details of BASIC Commands
error
Syntax:
ERROR
Statement. Simulates the occurrence of an error.
Description:
<error number> is any valid error number in the range: [1...255].
Remarks:
If a system error or a BASIC program error number is used the relevant error code will be put in
the IR n+7 word and, if applicable, the error message will be printed to the screen.
If an error number is specified that does not contain an error description, for instance an undefined
user-defined error or a system error code that is not used, then an "UNDEFINED ERROR" error
code will occur.
For both system and user errors it is possible to define error handling using the
statement.
ERROR
the operation of an error-processing program in an interrupt subroutine.
>
Examples:
>
>
>
>
>
ERROR #6 OCCURRED AT LINE 20
See also:
ON ERROR GOTO
exp
Syntax:
(<numerical expression>)
EXP
Function. Calculates the exponential of a numerical expression with base e.
Description:
Remarks:
<numerical expression> may be any integer, single-precision floating point or double-precision
floating point.
The return type is single-precision floating point if the argument is of type integer or single-
precision floating point. If the argument is of type double-precision floating point then the return
type is also double precision floating point.
>
Examples:
>
>
2.71828
See also:
156
<error number>
and
can be used together to simulate the occurrence of an error and test
ON ERROR GOTO
10 ON ERROR GOTO 1000
20 ERROR 6
30 END
1000 PRINT "ERROR #";ERR;" OCCURRED AT LINE ";ERL
1010 END
RUN
,
,
,
ERL
ERR
ERC
10 A = EXP(1)
20 PRINT A
RUN
7-6
Section
ON ERROR GOTO

Advertisement

Table of Contents
loading

This manual is also suitable for:

C200h-asc21C200h-asc31

Table of Contents