Difference between revisions of "MenuRes"
From Wiki
m |
(→Example) |
||
Line 9: | Line 9: | ||
==== Example ==== | ==== Example ==== | ||
<pre> | <pre> | ||
+ | menu Clear | ||
+ | menu Window Title Example | ||
+ | menu Window Color BtnFace | ||
+ | menu Window Size 117 95 | ||
+ | menu Font Transparent #true | ||
+ | menu Font Align Right | ||
+ | menu Font Name Default | ||
+ | menu Font Size 8 | ||
+ | menu Font Style | ||
+ | menu Font Color Black | ||
+ | menu Font Align Left | ||
+ | menu Check CheckBox1 8 8 97 17 #false Check Box 1 ;<-- CheckBox not ticked = #False | ||
+ | menu Check CheckBox2 8 32 97 17 #true Check Box 2 ;<-- CheckBox ticked = #True | ||
+ | menu Font Name MS Sans Serif | ||
+ | menu Font Color WindowText | ||
+ | menu Button OKButton 40 64 35 25 OK | ||
+ | menu Show 421 270 | ||
+ | |||
+ | MenuLoop: | ||
+ | Wait 1 | ||
+ | |||
+ | If #MenuButton <> OKButton ;<-- Check to see if OK button has been pressed. | ||
+ | Goto MenuLoop | ||
+ | |||
+ | Menu Get CheckBox1 ;<-- Gets the value from CheckBox1 menu item | ||
+ | If #MenuRes = #True ;<-- If #MenuRes is true the checkbox has been ticked | ||
+ | Set %CheckBox1 #True | ||
+ | Else | ||
+ | Set %CheckBoc1 #False | ||
+ | |||
+ | Menu Get CheckBox2 | ||
+ | If #MenuRes = #True | ||
+ | Set %CheckBox2 #True | ||
+ | Else | ||
+ | Set %CheckBox2 #False | ||
+ | |||
+ | Halt | ||
</pre> | </pre> | ||
+ | |||
==== See Also ==== | ==== See Also ==== | ||
{| | {| |
Revision as of 06:51, 15 August 2005
Result System Variables
Description
⇒
Holds the value from the last menu Get or Menu GetNum statement executed.
Example
menu Clear menu Window Title Example menu Window Color BtnFace menu Window Size 117 95 menu Font Transparent #true menu Font Align Right menu Font Name Default menu Font Size 8 menu Font Style menu Font Color Black menu Font Align Left menu Check CheckBox1 8 8 97 17 #false Check Box 1 ;<-- CheckBox not ticked = #False menu Check CheckBox2 8 32 97 17 #true Check Box 2 ;<-- CheckBox ticked = #True menu Font Name MS Sans Serif menu Font Color WindowText menu Button OKButton 40 64 35 25 OK menu Show 421 270 MenuLoop: Wait 1 If #MenuButton <> OKButton ;<-- Check to see if OK button has been pressed. Goto MenuLoop Menu Get CheckBox1 ;<-- Gets the value from CheckBox1 menu item If #MenuRes = #True ;<-- If #MenuRes is true the checkbox has been ticked Set %CheckBox1 #True Else Set %CheckBoc1 #False Menu Get CheckBox2 If #MenuRes = #True Set %CheckBox2 #True Else Set %CheckBox2 #False Halt
See Also
menu Get | menu GetNum |
Main_Page | Documentation | Result System Variables |