Chapter 12: Program Application
211
Chapter 12: Program Application
211
GetKey
I/O - Input
Syntax: GetKey
<variable name>
Function: This command assigns the code number of
the last key pressed to the specified variable.
Description:
• This command assigns the code number of the last
key pressed to the specified variable. The following
shows a list of available code numbers.
Key
Code
Key
Code
Key
Code
0
48
+
43
{
94
1
49
-
45
E
13
2
50
*
60944
f
28
3
51
/
47
c
29
4
52
=
61
d
30
5
53
(
40
e
31
6
54
)
41
k
144
7
55
,
44
K
145
8
56
z
45
f
8
9
57
x
60856
c
12
.
46
y
60857
e
147
Z
60858
• 0 is assigned to the variable if no key was pressed.
GetPen
I/O - Input
Syntax: GetPen
<variable name 1>, <variable name
2>
Function: This command assigns the coordinates of
the point tapped on the screen to a specified variable.
Description: This command assigns the
x
-coordinate
(horizontal axis) to <variable 1> and the
y
-coordinate
(vertical axis) to <variable 2>. The coordinates at the
point in the upper left corner of the screen are (1, 1),
and coordinate values are specified in the range of
1 to 320 for the
x
-coordinate and 1 to 528 for the
y
-coordinate.
GetType
Misc - Variable
Syntax: GetType
<variable name>, <storage
variable name>
Function: Gets the type of the specified variable and
assigns it to a storage variable as a text string.
Description: The following is a list of variable types.
• NUM*
1
• MAT
• FUNC
• MEM
• EXPR*
2
• PRGM
• PICT
• OTHR
• STR
• EXE
• GMEM
• NONE*
3
• LIST
• TEXT
• GEO
*1 Real number *2 Expression
*3 No applicable variable
For details about each type, see “Main Memory Data
Types” (page 28).
GetVar38k
I/O - Communication
Syntax: GetVar38k
<variable name>
Function: Receives variable names and variable
contents.
Description:
• The
OpenComPort38k
command must be executed
before this command is executed.
• The
CloseComPort38k
command must be
executed after this command is executed.
Goto~Lbl
Ctrl - Jump
Syntax: Goto
<label name> : Lbl
<label name>
Function: This command causes program execution
to jump to a specific location.
Description:
• <label name> is a text string that is subject to the
same rules as variable names.
•
Goto
and
Lbl
are used in pairs. Program execution
jumps from
Goto
to the
Lbl
with the same label
name. A single
Lbl
can be used as the jump
destination of multiple
Goto
commands.
• This command can be used to loop back to the
beginning of a program or to jump to any location
within the program.
• An error occurs if ClassPad is unable to find a
Lbl
with the same label as
Goto
.
• Note that the
#
command cannot be used in a label
name.
GraphType
Misc - Graph&Table(1)
Syntax: GraphType
"
y
=" ; "
r
=" ; "
xt
=" ; "
x
=" ; "
y
>" ;
"
y
<" ; "
y
t
" ; "
y
s
" ; "
x
>" ; "
x
<" ; "
x
t
" ; "
x
s
"
Function: Specifies the graph expression input type.
GTSelOff
Misc - Graph&Table(1)
Syntax: GTSelOff
<graph number>
Function: Deselects a graph expression.
Description: Graph number range: 1 to 100
GTSelOn
Misc - Graph&Table(1)
Syntax: GTSelOn
<graph number>
Function: Selects a graph expression.
Description: Graph number range: 1 to 100
H
Histogram
Misc - Statistics(1) - Graph
Function: Used as a
StatGraph
command argument
to specify an option. See
StatGraph
.
Horizontal
I/O - Sketch
Syntax: Horizontal
<
y
-coordinate>[,<color
command>]
Function: Draws a horizontal line.