Index...
Centrallix Documentation
|
report/table
table :: A tabular presentation of report data
Metadata:
type: | report/table |
visual: | yes |
container: | no |
Overview:
The table component is used to present data in an orderly, tabular fashion, in rows and columns. While less flexible than the form, it is much easier to use.
Tables, like forms, can have more than one 'mode'. However, tables only support 'normal' and 'inner'; 'outer' is not supported since tables do not contain other components. See the form documentation for more on the mode.
Tables also can handle multiple queries using a 'multimode' - see the form for more information.
Usage:
Tables can be used inside any visual container or inside forms. Tables can contain "report/table-row" objects. Table rows can contain either a set of "report/table-cell" objects, or other objects such as areas, data elements, and so forth. A row cannot contain both a table-cell and an object of another type.
Properties:
Property | Type | Description |
allowbreak |
yes/no |
Whether to allow the table to span multiple pages in the report. |
colsep |
double |
Sets the separation between the table's columns. |
columns |
integer |
The number of columns in the table. |
fixedsize |
yes/no |
If set to 'yes', then the 'height' setting (see Common Properties) is followed strictly, otherwise the table is allowed to grow vertically to fit its contents. |
innerborder |
double |
Width of the inside borders within the table. |
mode |
string |
The mode of the table (see overview). 'normal' is the default. |
multimode |
string |
How the table handles multiple queries (see overview). 'nested' is the default. |
nodatamsg |
yes/no |
Whether to display the '(no data returned)' message below the table if no records were returned from the query source. Default is 'yes' to display the no-data message. |
outerborder |
double |
Width of the outside border around the table. This sets topborder, leftborder, bottomborder, and rightborder simultaneously (see Common Properties). |
reclimit |
integer |
Sets a limit on the number of records the table is to print. |
shadow |
double |
Width of the drop-shadow to the right and bottom of the table. |
source |
stringvec |
A list of one or more query(ies) to run for this form. If more than one is specified, use the 'multimode' to determine how they are combined. |
widths |
intvec |
A list of numbers giving the widths of the columns. This MUST match the number of columns specified with the 'columns' setting. |
Child Properties:
(of report/table-row child widgets)
Property | Type | Description |
allowbreak |
yes/no |
Whether to allow the row to span multiple pages in the report. |
fixedsize |
yes/no |
If set to 'yes', then the 'height' setting (see Common Properties) is followed strictly, otherwise the table row is allowed to grow vertically to fit its contents. |
header |
yes/no |
Whether the row is a header row (repeated on subsequent pages). |
innerborder |
double |
Width of the inside borders between cells in the row. |
outerborder |
double |
Width of the outside border around the row. This sets topborder, leftborder, bottomborder, and rightborder simultaneously (see Common Properties). |
summary |
yes/no |
Whether the row is a summary row, emitted at the end of the table (no summarize_for) or at the end of each group of rows (if summarize_for is set). |
summarize_for |
expression |
An expression whose value uniquely defines the desired group of rows. The summary row is printed at the end of each group of consecutive rows having the same value for this expression. |
(of report/table-cell child widgets)
Property | Type | Description |
value |
expression |
The text to be printed inside the cell. Can reference report/query objects using :queryname:fieldname syntax. When the expression references queries, it should be enclosed in the runserver() domain-declaration function (see SQL Language / Functions and Operators for more details). |
Sample Code:
myTable "report/table"
{
source=myQuery;
columns = 2;
widths = 40,40;
hdr "report/table-row"
{
header = yes;
h_name "report/table-cell" { align=center; style=bold; value="Name"; }
h_size "report/table-cell" { align=center; style=bold; value="Size"; }
}
data "report/table-row"
{
t_name "report/table-cell" { align=center; style=bold; value=runserver(:myQuery:name); }
t_size "report/table-cell" { align=center; style=bold; value=runserver(:myQuery:size); }
}
}
Comments...
(none yet)
Add a Comment...
|