Sharp OZ-707 Operation Manual - Page 110

Resume, Right

Page 110 highlights

RESUME p FORMAT: 1. RESUME 2. RESUME NEXT 3 RESUME {line number} . *Iabel Abbreviation: RESU. See Also: ON ERROR GOTO PURPOSE: Resumes program execution at the end of an error handling routine. REMARKS: RESUME resumes program execution after completing an error handling routine to which control was passed by the ON ERROR GOTO command. This command validifies the ON ERROR GOTO command again. If control is returned to the main program by any other command (GOTO, etc.), execution will be aborted if an error subsequently occurs. The error handling routine lets you take the necessary action to prevent recurrence of the same error. Control is returned depending on the format: (1) Format 1 returns control to the statement which caused the error. If an error occurs again in the same statement, the error handling routine is executed again. (2) Format 2 returns control to the statement following the error statement. (3) Format 3 returns control to the specified line. EXAMPLE: 10: ON ERROR GOTO 100 20: INPUT A, B 30: PRINT AlB 100: RESUME 20 !f zetro iSti~ssign~ to variable B or an overflow occurs from AlB, control returns to the mpu rou ne on line 20 and prompts for COrrect data entry. RIGHT$ p o FORMAT: RIGHT$(string,N) Abbreviation: RI. See Also: LEFT$, MID$ PURPOSE: Returns N characters from the right end of a string. REMARKS: IFfr~acI.tSio.gnrsewatiellrbtehatnrunthceatneudm• IbfeNr o'ISf Iess than 1, a null stri.ng I.S returned characters in the string the whole . string IS returned. ' 208 209

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125
  • 126
  • 127
  • 128

RESUME
FORMAT:
1.
RESUME
2.
RESUME NEXT
3
RESUME {line number}
.
*Iabel
Abbreviation:
RESU.
See
Also:
ON ERROR GOTO
PURPOSE:
Resumes program execution at the end of an error handling routine.
REMARKS:
RESUME resumes program execution after completing
an
error
handling routine
to
which control was passed by the ON ERROR
GOTO command. This command validifies the ON ERROR GOTO
command again. If control
is
returned
to
the main program by any
other command (GOTO, etc.), execution will be aborted if
an
error
subsequently occurs.
The error handling routine lets you take the necessary action to
prevent recurrence of the same error.
Control is returned depending on the format:
p
(1)
Format 1 returns control to the statement which caused the error. If
an
error occurs again in the same statement, the error handling
routine is executed again.
(2)
Format 2 returns control to the statement following the error
statement.
(3)
Format 3 returns control to the specified line.
208
EXAMPLE:
10:
ON
ERROR GOTO 100
20: INPUT
A,
B
30:
PRINT AlB
100: RESUME 20
!f
zetro
iSti~ssign~
to
variable B or
an
overflow occurs from AlB, control returns
to
the
mpu
rou
ne
on
line
20
and
prompts for
COrrect
data entry.
RIGHT$
FORMAT:
RIGHT$(string,N)
Abbreviation:
RI.
See
Also:
LEFT$, MID$
PURPOSE:
Returns
N
characters from the right end of a string.
REMARKS:
Fractions will be truncated If
N'
I
th
.
.
.
IS
ess
an
1,
a null string
IS
returned
If
~
IS.
greater than
the
number of characters
in
the string the whole .
string
IS
returned.
'
209
p
o