Column definitions
The columns of a TABLE container are defined with item tags in the
LAYOUT section, and their corresponding form field definition in the
ATTRIBUTES section.
Each item tag used in the data line definition of a TABLE container must have a
corresponding element in the ATTRIBUTES section, to define decoration and
functional attributes of the column.
As we do not want to display all columns of the SQL table directly in the
TABLE
container, we define some form fields as PHANTOM. These fields will be used in the
screen array and program variable, but they will not be part of the list view in the layout section: 30 ATTRIBUTES
31 EDIT f1=customer.cust_num;
32 EDIT f2=customer.cust_name;
33 PHANTOM customer.addr;
34 EDIT f3=customer.city;
35 EDIT f4=customer.state;
36 EDIT f5=customer.zipcode;
37 PHANTOM customer.contact_name;
38 PHANTOM customer.phone;
39 TEXTEDIT f6=FORMONLY.cr_addr, STRETCH=BOTH;
40 EDIT f7=FORMONLY.cr_contact_name;
41 EDIT f8=FORMONLY.cr_phone;
42 ENDNote:
- Lines
31,32,34,35and36defineEDITform fields that correspond to the item tags used in theTABLEcontainer. - Lines
33,37and38definePHANTOMfields, that will be part of the data record list, but are not used on the list view of the layout section. - Lines
39,40and41define form fields used in theGRIDcontainer. These are not part of theTABLEcontainer and will be managed specifically by the program code.
Form fields used in a table container must be grouped in a Screen Array.