Download User manual

Transcript
Template
Alternatively, the tabular type shows all records in table-like view. (fig. 13.2).
Figure 13.1 Tabular template
As we said, the templates are jrxml files (the extension used for it is simply xml)
and they are located in the templates directory. iReport recognizes from the name if
a file contains a columnar or a tabular template: if the file name ends with T, it will
be used as tabular, while if it ends with C, it will be interpreted as columnar.
Here it is a list of templates shipped with iReport;
File
Report type
classicC.xml
classicT.xml
classic_landscapeT.xml
graycC.xml
grayT.xml
gray_landscapeT.xml
Table 13.1 Templates shipped with iReport
Columnar report
Tabular report
Tabular report
Columnar report
Tabular report
Tabular report
The wizard permits the creation of up to four groups (a Group Header and Group
Footer is associated with each group). These groups will be created in the produced
final file only and only if during the wizard execution the user asks for grouping
data by using one or more criteria. Using the wizard you can choose only a field
name as criteria.
By opening classicC.xml file, it is possible to see and understand how a template is
structured. In this file you will find four groups: Group1, Group2, Group3 and
Group4, for which the title band (group header) and the group footer are visible.
The columns band is hidden (because for columnar reports this band is not useful)
and in the detail there are static text labels used as template label for every future
field as on figure 13.1, and a textfield containing the real field. The text (or the
expression dealing with textfield) associated with the text elements has to follow the
simple wizard specifications, in particular each group can contain as many graphic
elements you want and a static text element containing simply this text:
GnLabel
135