GUI ScreenIO for Windows |
The field definition of a radiobutton, like a checkbox, consists of a simple PIC 9 area, and an 88-level for its two possible values: ON or OFF:
01 panel-4.
|
It's very simple to set the state of a radiobutton using the 88-level values:
To set the state of a radiobutton to ON (checked):
SET MY-RADIOBUTTON-A-ON TO TRUE. |
To set the state of a radiobutton to OFF (not checked):
SET MY-RADIOBUTTON-A-OFF TO TRUE. |
The next time you call GUI ScreenIO to display your panel, the radiobutton will show the value that you set in your program.
If you attempted to check more than one radiobutton in a group, GUI ScreenIO will only check the last one when the panel is displayed. That's because radiobuttons are mutually exclusive; only one radiobutton in a group may be checked; all the rest will be unchecked.
When control returns from GUI ScreenIO, you test the state of the checkbox using the 88-level items, like this:
EVALUATE TRUE
|
Or, if you prefer using IF statements:
IF MY-RADIOBUTTON-A-OFF
|
© 2000-2019 Norcom, all rights reserved |