|
Question: How do I add fields
or adjust the layout of a report?
Answer: ExpressMaintenance
includes a very powerful built-in report builder. All of the
standard reports included with ExpressMaintenance are built using the report
builder. It is often
desirable to adjust reports to include or exclude certain fields.
While you can develop new reports from scratch, it is usually easiest to
edit an existing report that is close to the desired results.
This example will show how to alter
a simple report. It provides some introductory concepts of using
the report builder. More advance uses of the report builder are
certainly possible. However, it is best to have some knowledge of
database and report design concepts.
You should make sure
your toolbars are enabled in Report Builder. You can do this under
View / Toolbars. We recommend enabling each toolbar except Report Tree and
Data Tree. You can also arrange the tool bars by dragging them
around in the window.
The report used in this example is
the Units List By Location report. We will add the Unit number
field to the report. Adding a field to a report involves two
primary steps. All reports are made up of two building blocks
which produce the report that is previewed and printed. These
include:
-
Query to extract the desired data
-
Layout / design presentation of the data
First, the field must be included in
the query (search) and be included as part of the returned results.
Secondly, the data field must be included in the report design to appear
on the report.
Add Data Field To The Query
-
Run the Unit List By Location report to preview on the screen.
-
Click on the Data tab of the report builder.
-
The Units table will appear as a box in the upper left portion of the
screen.
-
The Units window includes several buttons that make up the Query
Designer.
-
Click on the Fields button to open the Query Designer to the Fields tab.
-
The upper section reflects the available fields and lower section
reflects selected fields.
-
Add the "Unit" (for example) field to the report query by locating the "Unit" field
in the upper section and double click on it. This adds the Unit field to the bottom portion
of the screen.
-
Edit the query filter
criteria using the operator and value desired.
-
Check AutoSearch to make the
query dynamic meaning it can be changed each time the report is
executed. Check mandatory to require the filter each time.
-
Click the Ok button to save the changes in the Query Designer.
-
You can view the raw query results by clicking on the Preview button in
the Units window.
-
To
learn more about the Query Designer, review the help under Report
Builder.
Add Field To The Layout
-
Click on the Design tab of the report designer.
-
Locate the Data Components toolbar which is on the top row by default.
The first button
appears to have an "A" in front of a table. When pointing at the button,
the popup hint reads "DBText". This component is for
displaying standard data fields. If adding a memo field, you will
want to use the DBRichText component follow these steps plus notes
below.
-
Click the DBText button and then click in the Detail band of the report
layout. A DBText component will be place in that location.
-
Click the Place tab in the Page Designer dialog.
-
Size and adjust the DBText component as desired.
-
Left click on the DBText component and then look in the upper section to
locate the table Data Pipeline and Data Field drop down selection
fields.
-
Select the Units Data Pipeline if not already selected.
-
For the Data Field, drop down the list and select the desired field such
as Unit. This associates the DBText component with the Unit number
field.
-
Click the Preview to view the results.
-
To
add a label for the Unit field, click on the Label component and place
it in the header band. In the upper section, edit the caption of
the label to read "Unit Number" or other desired value.
-
Click the Preview tab to view the results.
-
On
exit of the report, save your changes.
Other Notes
-
If you are placing a notes field in the report,
use the Advanced DBRichText component
rather than a DBText component. You will also need to set the band
to dynamic height and the component to stretch. These properties
are set by right clicking on the object.
-
If
you are placing a graphic field in the report, use a DBImage component
rather than a DBText component. You will also need to set the band
to dynamic height and the component to stretch.
-
For more comprehensive help on the report builder, view the help or
other Tech Bulletins.
You can download original report
definitions for all reports -
click here for list. |