Was this helpful?
Set_forms
Sets a variety of features of the FRS (FRS).
Syntax
set_forms objecttype {parentname
  (set_forms_constant [(objectname)] = value 
  {, set_forms_constant [(objectname)] = value})
objecttype
The type of object for which the value assignment sets features:
frs
Is FRS itself
form
Is a form
field
Is a simple field
row
Is a row in a table field
column
Is a column in a table field
menu
Is a menuitem on the form
The objecttype is a 4GL name and must be a character string.
parentname
The form, or form and tablefield, that contains the object being set. For a simple field or menu item, parentname is the form name. For a row or column in a table field, parentname is the form name and the table field name.
An empty string (' ') here indicates the current parent.
For example, in a set_forms field statement, parentname is the name of the form in which the field appears. The following statement sets the blink attribute on the field "emp_name" in the current form:
set_forms field ' ' (blink(emp_name)=1);
The parentname is a 4GL name.
parentname is not used when the object type for the statement is FRS or form.
set_forms_constant
FRS constant. Allows various features of the FRS to be set from within an application during program execution.
FRS constants are global; they apply to all forms in the application.
objectname
The object to which the set_forms_constant refers; a 4GL name. It can be a column, field, form, table-field row, menu, or variable of an Ingres data type (Default = current object).
Use a dereferencing colon (:) before the objectname if it is a local variable.
value
A character string or integer value as specified for each set_forms variant. The value must be within the limits specified for each set_forms constant.
Description
The 4GL set_forms statement allows you to set various features of the FRS (FRS) dynamically. The FRS handles the management of the forms that are displayed as the application runs.
Among the FRS features that can be set with this statement are:
Display attributes for simple fields and table-field columns and rows
Field validations and activations
Mapping for control and function keys
Once set, the FRS options remain in effect until the application is exited or until a new statement clears them.
A corresponding inquire_forms statement exists for each variant of the set_forms statement. You can query and set features dynamically as required throughout an application.
IMPORTANT!  CAUTION! The individual assignments specified in a set_forms statement are processed in reverse order. Thus, earlier assignments take precedence over later assignments in the same set_forms statement. For example, to specify both label and map for a key, specify label before map. Otherwise, the default label generated by the map overrides the label you specify.
The set forms statement has two variants, set_forms formobject and set_forms frs, determined by the objecttype being set. Each type is discussed in its own section below.
Set_forms Formobject, covers statements which take an objecttype of form, field, column, row or menu.
Set_forms FRS, covers only statements which take the objecttype frs.
Last modified date: 01/30/2023