Form items / Form tags |
Item tags define the position and size in a grid-based container.
An item tag defines the position and size of a simple form item in a grid-area of a GRID or SCROLLGRID container. Form item defined with item tags are leafs in the structure of a form definition, such as a form field (i.e. it is not a container form item).
[identifier [-] [|...]]
An item tag is delimited by square braces ([]) or pipes (|) and contains an identifier used to reference the description of the form item in the ATTRIBUTES section. In the next example, the identifier of the form item is "f01", and the form item type is BUTTONEDIT:
LAYOUT GRID { ... [f01 ] ... } END ... ATTRIBUTES BUTTONEDIT f01 = customer.cust_name, ACTION=zoom; ...
GRID { Name: [f001 ] } END
GRID { 1234567890 [f1] } END
By default, the real width of the form item is defined by the number of characters used between the tag delimiters.
GRID { 1234567 [f1 ] -- this EDIT gets a width of 7 [f2 ] -- this BUTTONEDIT gets a width of 5 (7-2) } END
GRID { 1234567 [f1 - ] } END
GRID { Info: [f001 |f002 |f003 ] } END
GRID { Multi-segment: [f001 ] [ ] [ ] [ ] [ ] } END
The notation applies to the new LAYOUT section only. For backward compatibility (when using a SCREEN section), multiple-segment items can be specified by repeating the identifier in sub-lines.
GRID { Single-line static screen array: [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] } END
GRID { Multi-line static screen array: [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] [f001 ] [f002 ] [f003 ] } END