Report Editor - Table Help
The Table control is intended for showing records of specified query in the grid. It was introduced with the version 6.4.
Table control has two major properties that affect its work:
- columns – defines the number of columns, their contents and style.
- query – the source query of the control.
You can change these and other properties of the table using Properties Inspector for the control.
The property columns has a special Columns Editor dialog. It can be shown either using the the Property Inspector, or by double-click on the table control.
Table layout can have from 1 to 4 regions:
- Header – optional, controlled by has_header property
- Body – obligatory
- Footer – optional, controlled by has_footer property
- Total – optional, controlled by has_total property
Each region is represented as a single row in the layout:
Height of each region, style and contents can be defined using the Columns Editor dialog.
Table header is printed at the beginning of the table and at the beginning of each report column.
Usually a column title text should be placed in this region.
Table with header is presented in the design mode on the following picture:
Table body region is printed for each record of the source query.
As usual it contains values of fields.
Table with body only is presented in the design mode on the following picture:
Table footer is printed at the end of each report column.
It may contain static text, but also it is able to show summary for column values in the current report column.
Table with footer is presented in the design mode on the following picture:
Table total is printed at the end of the table.
It may contain static text, but also it is able to show summary for column values of all of the rows of the source query.
Binding With Report
Like subreport, a table control shows records from the query. This query can be completely independent from the report in the simplest case:
Or it can return records, related to the current record of the report. To define this relation you can use one of the following ways (using Properties Inspector):