SET PREMENU

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

Jump to: navigation, search

SET PREMENU

Class

Screen Forms


Purpose

Designate an event-driven trigger procedure to execute prior to entering a menu


Syntax

SET PREMENU TO [<procedure-name> / (<expC>)]


See Also

@...GET, @...MENU, CREATE SCREEN, MODIFY SCREEN, SAVE MENU, SET PREFORM, SET POSTFORM, SET POSTMENU, SET POSTRECORDTO, RESTORE


Description

The PREMENU trigger procedure executes a procedure before the first @...MENU is activated from within a form. The SET PREMENU TO <procedure-name> command defines the procedure or program name to be executed. The filename can be substituted with a <expC>, enclosed in round brackets, which returns a valid filename. The PREMENU trigger is called when the [MENUBAR] is activated. The SET PREMENU TO command clears the active <procedure-name>.

The SET PREMENU trigger can also be defined from within the SCREEN PAINTER work surface. The PREMENU procedure option from the TRIGGERS menu is used to define the trigger name. The [HELP] key may be pressed here to edit the trigger file from inside the SCREEN PAINTER.


Example

procedure pre_security
// Check group ID number, if not valid, prohibit menu access
if getgid() < 100
dialog box "Restricted Menu Options"
keyboard(chr(ctrl(’g’)))
endif
return


Products

Recital Mirage Server, Recital Terminal Developer