HP Prime Graphing Wireless Calculator User Manual
Page 301
Programming in HP PPL
297
ISKEYDOWN
Syntax: ISKEYDOWN(key_id);
Returns true (non-zero) if the key whose key_id is provided
is currently pressed, and false (0) if it is not.
MOUSE
Syntax: MOUSE[(index)]
Returns two lists describing the current location of each
potential pointer (or empty lists if the pointers are not
used). The output is {x , y, original z, original y, type}
where type is 0 (for new), 1 (for completed), 2 (for drag),
3 (for stretch), 4 (for rotate), and 5 (for long click).
The optional parameter index is the nth element that
would have been returned—x, y, original x, etc.—had the
parameter been omitted (or –1 if no pointer activity had
occurred).
MSGBOX
Syntax: MSGBOX(expression or string [ ,ok_cancel?]);
Displays a message box with the value of the given
expression or string.
If ok_cancel? is true, displays the
and
buttons, otherwise only displays the
button. Default
value for ok_cancel is false.
Returns true (non-zero) if the user taps
, false (0) if
the user presses
.
EXPORT AREACALC()
BEGIN
LOCAL radius;
INPUT(radius, "Radius of Circle","r =
","Enter radius",1);
MSGBOX("The area is " +
π*radius^2);
END;
If the user enters 10 for
the radius, the message
box shows this: