ON SELECTION BAR

From Recital Documentation Wiki
Revision as of 15:54, 12 November 2009 by Helengeorge (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Purpose

Defines commands for pop-up menu selection


Syntax

ON SELECTION BAR <expN> OF POPUP <popup> [<command>]


See Also

ACTIVATE POPUP, DEACTIVATE POPUP, DEFINE BAR, DEFINE POPUP, ON BAR, ON EXIT BAR, ON EXIT POPUP, ON POPUP, ON SELECTION POPUP, SET COMPATIBLE, SHOW POPUP


Description

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.

<command>

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.


Example

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


Products

Recital