Other Content

Table Of Contents
496 Getting Started with the Program Editor
Requesting the Values from the User (Programs Only)
You can use the Request and RequestStr commands in a program to make the
program pause and display a dialog box prompting the user for information.
This method does not require users to remember variable names or the order
in which they are needed.
You cannot use the Request or RequestStr command in a function.
1. Define the program.
Define calculatearea()=
Prgm
Request "Width: ",w
Request "Height: ",h
area:=w*h
EndPrgm
2. Run the program and respond to the requests.
calculatearea() : area
Width: 3 (3 entered as a response)
Height: 23.64(23.64 entered as a
response)
70.92
Use RequestStr instead of Request when you want the program to interpret the
user’s response as a character string rather than a math expression. This
avoids requiring the user to enclose the response in quotation marks (““).
Displaying Information from a Function or Program
A running function or program does not display intermediate calculated results
unless you include a command to display them. This is an important difference
between performing a calculation on the entry line and performing it in a
function or program.
The following calculations, for example, do not display a result in a function or
program (although they do from the entry line).
©
x:=12•6