Form XML code and CSS element selector
Most commonly used form properties
Table container allows creating tables for data input and display.
Form tables have a hierarchical structure in which the Table container is the parent.
Each widget placed inside of the Table container will appear under a separate table column.
Table container with two columns:
<Table identifier="c1" visible="true">
<TableColumn text="column" resizable="true" visible="true">
<TableColumn.columnLength>
<GridLength/>
</TableColumn.columnLength>
</TableColumn>
</Table>
CSS element filter:
.qx-aum-table
Most commonly used form properties:
unsortableColumn
Associated ui.Table methods:
Create
ForName
Associated ui.TableColumn methods:
Create
ForName
SetColumnLength
GetColumnLength
SetColumnNum
GetColumnNum
SetControl
GetControl
SetEditControl
GetEditControl
SetFooter
GetFooter
SetReadOnly
GetReadOnly
SetResizable
GetResizable
SetSorted
GetSorted
SetText
GetText
SetUnsortable
GetUnsortable
To add a Table to your form, you
Step 1. Choose a Table from the form containers in Palette.
Step 2. Put it in the form.
Table identifier is linked to the identifier of the screen record nesting the table column fields. Therefore, editing one of these IDs automatically changes the other.
Each widget placed into the Table appears in a separate table column. When you add other columns, they automatically fill the table width.
To specify a column header, set the necessary name in the column Text property:
To rearrange the order of columns, drag a column, and drop it at the necessary place:
You can change the width of columns by dragging their right or left edges, if the column width is specified in pixels (see gridLength):
Tables and TableColumns comply with these layout rules:
By default, tables in .fm2 forms do not have horizontal scroll bars – only vertical ones.
To add a horizontal scroll bar to your Table, you must set allow-horizontal-scroll as its classname:
After this, your Table will get a horizontal scroll bar at runtime when (but only when) these conditions are met:
Column width was set explicitly (not in % or as Auto).
Otherwise, at runtime your browser will try to fit table columns into the available space (= spread them through out the table width).
The sum of your column widths is greater than the width of the table.
For example, you will get a horizontal scroll bar if your table is 500 px wide and has two columns of 300 px: 500 px < 300 px + 300 px.
You will not get a horizontal scroll bar if your table is 500 px wide and has two columns of 200 px: 500 px > 200 px + 200 px.
A screen record, where all fields from the table are added, is automatically created:
It is the screen record name that is to be referenced in 4GL to display or input arrays. When you change the order of the table columns in the Form Editor Area, the order of the column field names is not changed in the corresponding screen record.
Therefore, after the columns are arranged, it may be necessary to rearrange the screen record list. To do it, click the fields button to the right of the fields list. This will call the dialog window, where the fields can be moved or deleted:
Table shares with TreeTable some unique properties: