ON SELECTION BAR
Defines commands for pop-up menu selection
ON SELECTION BAR <expN> OF POPUP <popup> [<command>]
The ON SELECTION BAR command defines a command that will be executed when the specified menu bar is selected. A menu bar is a selection option in dBASE-IV style pop-up menus. Pop-up menus of this type are created with the DEFINE POPUP and DEFINE BAR commands. The bar is identified by the numeric expression <expN> that was assigned with the DEFINE BAR command. The pop-up is identified by its name which was assigned with the DEFINE POPUP command. The command SET COMPATIBLE should be ON when using dBASE IV style menus.
To specify commands which execute when the menu bar is highlighted, use the ON BAR command. To specify commands that execute when the menu bar is exited, use the ON EXIT BAR command.
define menu main define pad exit of main; prompt "\<Exit" at 0,0 define pad filelist of main; prompt "\<Files" at 0,6 on pad filelist of main activate popup files on selection pad exit of main deactivate menu define popup files from 1,06 define bar 1 of files prompt "\<Programs" define bar 2 of files prompt "\<Databases" on selection bar 1 of popup files; dialog box "Bar 1" on selection bar 2 of popup files; dialog box "Bar 2" activate menu main