Was this helpful?
Frame Activations
4GL provides the following types of activations you can use to define and control the user's possible courses of action within a frame:
Initialization
An initialization causes a specific operation to occur before the frame is displayed. The syntax for an initialization is:
initialize (parameter declarations)
declare (variable declarations) =
begin
statements
end
Menu Activation
Menus appear on the menu line, across the bottom of the frame. They provide options, known as menu operations, from which the user can choose. On a user-specified frame, each menu operation invokes processing that you specify with 4GL. Additionally, you can use submenus for a variety of purposes.
The syntax for a menu item is:
'Menuitem '=
begin
statements
end
Key Activation
A key activation causes a specific action to occur whenever you press a particular key. The syntax for a key activation is:
keyname =
begin
statements
end
Field Activation
A field activation causes a specific action to occur whenever the user moves the cursor into a new field or out of a field after changing the value in that field. The syntax for a field activation is:
field fieldname =
begin
statements
end
Time‑out Activation
A time‑out activation causes a specific action to occur whenever the user allows a set period of time to pass without pressing any keys. The syntax for a time‑out activation is:
on timeout =
begin
statements
end
Database Event Activation
A database event activation occurs when one of the other activations causes the presence of a database event to be detected. The syntax for a database event activation is:
on dbevent=
begin
statements
end
Last modified date: 08/14/2024