MENU FIELDS

From Recital Documentation Wiki
Revision as of 11:10, 17 March 2009 by Yvonnemilne (Talk | contribs)

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

MENU FIELDS

Class

Menus


Purpose

Select a field list from a menu


Syntax

MENU FIELDS

[AT <expN1>,<expN2>]

[BOLD]

[CLEAR]

[COMMAND <expC1>]

[INDEX]

[LABEL <expC2>]

[NUMERIC]

[OFF]

[POPUP]

[QUIT]

[SELECT <expC3>]

[SKIP]


See Also

@...MENU, MENU, MENU AT, MENU COMMAND, MENU FILES, MENU FORMAT, MENU FRAME, MENU QUERY, MENU SCOPE, SET DESCRIPTIONS, MENU(), MENUITEM()


Description

The MENU FIELDS command displays a menu of fields from the current table.

AT <expN1>,<expN2>

The menu can optionally be positioned at the specified row <expN1> and column <expN2> positions.


Keyword Description
BOLD The menu frame is highlighted.
CLEAR The inside of the menu frame is cleared before displaying the menu.
COMMAND <expC1> The command <expC1> and all selections made from the menu are displayed in the action line (line 22).
INDEX All of the selected fields are converted to character data types suitable for indexing on mixed data types.
LABEL <expC2> The specified character string <expC2> is displayed at the top of the menu frame.
NUMERIC Only the numeric fields from the table will be included in the menu.
OFF The display of messages in the message line is disabled.
POPUP The screen is automatically saved when the menu is displayed, and restored when the menu is cleared.
QUIT When the QUIT option is specified, the [ABANDON] key exits the menu.
SELECT <expC3> Multiple selections can be made. The MENUITEM() function can be used to return a string containing the selections made, each separated with <expC3>. Selections are made by placing the cursor on the required menu item and pressing the [RETURN] key. Once all the required selections have been made, the [EXIT/SAVE] key is used to save them or the [ABANDON] key will cancel them. The ASTORE() function can be used to place all the selections into separate array items.
SKIP Selections can be made from more than one table. The [CURSOR RIGHT] key skips to the next workarea, and the [CURSOR LEFT] key skips to the previous workarea. Names of fields from other workareas will be prefixed with the workarea alias pointer, e.g. patrons->name.


If the SET DESCRIPTIONS command is set to ON, field descriptions are listed within the menu instead of field names. The currently selected field name, type and width are displayed above the field descriptions. When SET DESCRIPTIONS is set to OFF, the reverse is true: the currently selected field description displays above the menu of field names, types and widths.


The following keys are active in MENU FIELDS:


Key Action
[PAGE DOWN] Display the next page of fields
[PAGE UP] Display the previous page of fields
[CURSOR UP] Skip to the previous field or previous page if on the top field of a page
[CURSOR DOWN] Skip to the next field or next page if on the last field of a page
[CURSOR RIGHT] Display fields from next workarea
[CURSOR LEFT] Display fields from previous workarea
[RETURN] Select a field
[ABANDON] Discard selected field and exit
[EXIT/SAVE] Exit with selected fields


On exit from MENU FIELDS the MENUITEM() function will return the field list as a character expression. If the [ABANDON] key was pressed, or no fields were selected, then MENUITEM() will return a null string and MENU() will return –1.


Example

menu fields at 2,0;
label "Fields" select "," skip
store menuitem() to fieldlist
display all &fieldlist


Products

Recital Terminal Developer