Workbench User Guide : Creating and Modifying Menus : Create a Menu : How Menu Items and Variables Work
 
Share this page          
How Menu Items and Variables Work
As with fields, each menu item can be associated with a 4GL variable. The menu item displays information to the user, and the variable associated with the menu item can be used by your application to set or return a value for that menu item process.
Workbench creates the corresponding variable for a menu or menu item when you enter a variable name in the Property Inspector. In your 4GL code, you can access the menu field only through its corresponding variable.
For more information about using menu item variables in your 4GL scripts, see the MenuField class section in the Language Reference Guide.