Tutorial 3 - Building the Customers Print Template
The Customers report lists the purchasing history of a given customer. In this Tutorial, we will build the print template that formats the report page, and since the process of creating a template has already been covered in detail in Tutorial1, here we will only show the basic steps.
Open a new Print Template Workspace window and drag the following Title fields and Underlines into it:
The report header ("Customer History") font should be Sans Serif Bold 12; the other headings should use Sans Serif Regular 10. Also note that we used double underlines for headings; this is controlled through the Inspector (the Underline component must be selected in the Workspace):

Next, we bring in the following Customers table fields into the print template:
We already used these fields in CustomerList template, but there they were part of the Body segment, and here we place them in the Header segment of the template. Also, we will add more headings (Title fields) and single Underlines as shown in the following figure:
Finally, we add the Body segment with these fields from the Orders table:
Two of the template fields - OrderDate and ShippedDate - are of Date type, as shown in the Inspector:

Print fields of Date type have to be assigned a date format to be used for printing the date. The date formats are listed in the Formatting box at the bottom of the Inspector; the list comes from the Date Formats editor (Edit > Edit Date Formats menu item of the Workspace window) that can be used to add new date formats to the default format list shipped with Scribe.
Another aspect of Date-type fields that is worth mentioning here is the enabled status of the data type pop-up list in the Inspector. The database fields have their data type fixed at the time of creating the table, so the Inspector merely shows the data type without letting the user change it - hence, the pop-up list is normally disabled for this type of print fields.
However, table fields that carry dates are of DATETIME type, which means that they can carry both date and time. Scribe requires that print fields be of either DATE or TIME data type, so in this case the pop-up list is partially enabled to give the user a chance to select which part of the field content to show in the report.
Save the print template as Query/Customers.
![]()