11-8 Applications
The program below lets you store the values for the current Window variables,
and it lets you display a graph using previously stored values. It also
demonstrates a method for including menus in a program.
PROGRAM:WINMEM
:CLRHOME
:DISP "WINDOW MEMORY"
:DISP "1:STORE WINDOW"
:DISP "2:RECALL WINDOW"
:DISP "3:QUIT"
:DISP " "
:DISP "ENTER 1,2, OR 3"
:INPUT M
Present menu of
choices.
:IF M=1
:GOTO S
:IF M=2
:GOTO R
:GOTO Q
Evaluate menu
selection.
:LBL S
:XMINA
:XMAXB
:XSCLC
:YMIND
:YMAXE
:YSCLF
:DISP "WINDOW STORED"
:GOTO Q
Store current graph
Window variable values.
:LBL R
:AXMIN
:BXMAX
:CXSCL
:DYMIN
:EYMAX
:FYSCL
:DISPGRAPH
Display graph with
previously stored
v
ariable values.
:GOTO Q
:LBL Q
:STOP
Quit program.
Program: Window Variables Store and Recall
Program