FUNCTION STATEMENT IN FORM LAYOUTS

FUNCTION allows the implementation of function keys (or hot keys).  Once the function key trigger is defined, it is valid for all Forms and Menus invoked while the current Menu or Fill is active.  There is no limit to the number of levels in which the function key trigger can be used.  (The function key trigger can be overridden at any time by a lower level Fill or Menu being executed with its own function statement.)

SYNTAX

[/FUNCTION function_trigger_name]

function_trigger_name

name of trigger that will execute when a valid function key code is entered (from @FUNCTION_LIST).  @FUNCTION_CODE stores the specific function key code entered.  The trigger will specify which function key performs which function.

EXAMPLE

/  FUNCTION KEY_OPTIONS

NOTE:  This allows the execution of the trigger when a FILL layout is being executed no matter where the user is in the execution of the FILL.  It could execute another FILL to get additional information or terminate the current fill.

If you have defined 3 layouts with FUNCTION statements in each then which trigger that gets executed will depend on which layout the person executing the application is in when a key defined in the function key list is entered.

If only one of the layouts have a FUNCTION statement then it does not matter which layout is being performed so long as the one with the FUNCTION statement has been performed.

SEE ALSO:  @FUNCTION_LIST, @FUNCTION_CODE.

Back to Border Statement    Next page Message Statement