Skip to main content

Creating a Report Template

This page explains how to prepare an Excel report template, which fields can be written into it and how to upload, change, download and delete templates. For report types, output formats and where users generate reports, see the Report Templates Overview.


Steps to Add a Report Template​

1. Open the Function Designer​

Click Function Designs under the Administration menu.

2. Open the Report Templates of the Function​

  • On the Functions list, find the function whose records will be printed.
  • Click Report Templates in the row actions.

3. Look Up the Fields You Can Use​

  • Click Template Fields at the top of the page and select the Report Type you are designing for. Copy the fields you need, or click Download as Excel to get the full list.

4. Prepare the Excel File​

5. Upload the Template​

  • Click New. In the drawer that opens on the right, enter the Name, select the Report Type and Output Format, optionally enter a Description, and select the Excel file in the Template area.
  • Click Save. The template is now offered to users in the Reports button or row action of the function.

Drafting a Template with AI​

Instead of preparing the Excel file yourself, you can let the design assistant write it. At the top of the New drawer, describe the report (for example "Open nonconformities with their responsible and category") and click Draft with AI:

  • The AI picks the columns from the function's own fields, and the system writes the Excel template and places it in the Template area. The Name and, unless you chose one yourself, the Report Type are filled in; Output Format defaults to Original.
  • A message lists the columns used: "The template was written with these columns: ... It is attached below; save to keep it." Fields that do not exist in this report are named and left out.
  • Download the trial output downloads the template printed once on the records, so that you can check the result before saving.
  • Nothing is saved until you click Save. The button requires the Design assistant permission and AI for the tenant.

Fields of a Report Template​

Required fields are shown in bold.

Field NameDescription
NameThe name users see when they choose a report, and the name of the generated file. At most 100 characters.
DescriptionOptional explanation of the template, at most 500 characters.
Report TypeList, Detail or Master Detail. It decides where the template is offered and which fields can be used.
Output FormatOriginal (Excel), Pdf, or User Defined (the user chooses each time).
TemplateThe Excel file (.xls or .xlsx). Required when the template is created. When editing, a badge shows that a file is already attached; select a new file only if you want to replace it.

Template Actions​

ActionWhat it does
EditOpens the template's fields. You can change the name, description, report type and output format, and upload a new Excel file to replace the current one.
DownloadDownloads the current Excel file of the template, so that you can change it and upload it again.
DeleteDeletes the template after a confirmation. It is no longer offered to users.
Template FieldsOpens the list of fields that can be used in a template of the selected report type.

Template Fields List​

The Template Fields window ("Fields you can use in a report template") lists the fields of the function for the selected Report Type:

  • Field: The field exactly as it must be written into the cell, with a copy button. A "Copied" message confirms the copy.
  • What it prints: A description of the value. Values printed from fixed option lists are marked "(printed in English)".
  • Search fields: Filters the list by field or description.
  • Download as Excel: Downloads the list as an Excel file named "Report template fields".

The fields are grouped as follows:

GroupContentsReport types
Fields of the recordThe fields of the record itself, written as {{Field}}.All
Linked recordsFields of records linked to the record, written as {{LinkedRecord.Field}}. A detail report offers only the linked records it loads.All
List rows (repeat for each record)Fields of the rows of the record's lists, written as {{List.Field}}. A row of the template that holds such a field repeats downwards once for each row.Detail, Master Detail
List totalsThe number of rows of a list and the totals of its numeric fields, written as {{List.Count}} or {{List.Sum.Field}}.All
Parametric fieldsThe extension fields of the function, written as {{ExtendedProperties.FieldKey}}. They print the value as it appears on the screen (for example the option label instead of its code).All

Field, LinkedRecord and List stand for the real names; always copy them from the Template Fields window.


Writing Fields Into the Template​

  • Syntax: Type each field exactly as listed: same upper and lower case, no spaces inside the braces, for example {{Code}}. A field that is not listed, or has no value, prints empty.
  • Text and values: By default a field is written into the cell as text. To write a number or a date that Excel can calculate with, add _Value before the closing braces, for example {{Field_Value}}.
  • Totals: {{List.Count}} prints the number of rows of a list and {{List.Sum.Field}} the total of a field. Write .Avg., .Min. and .Max. instead of .Sum. for the average, the smallest and the largest value.
  • List reports: Each record is printed on one row. Write the fields of one record on a single row; it is repeated for every record of the list. Put the fields on the first worksheet of the workbook.
  • Detail and master-detail reports: A row holding a field of a list repeats downwards, once for each of its rows. Leave enough room under such rows, or place the list at the end of the sheet, so that the repeated rows do not overwrite other content.
  • Layout: Everything else in the workbook (texts, borders, merged cells, images, print area, headers and footers) is kept as designed. Formulas are recalculated after the fields are filled.

Example​

A simple detail template could look like this in Excel:

AB
1Code{{Field1}}
2Name{{Field2}}
3Number of rows{{List.Count}}
5RowAmount
6{{List.Field1}}{{List.Field2_Value}}

Row 6 repeats for each row of the list. Replace Field1, Field2 and List with real names taken from the Template Fields window.


⚠️ Warning​

  • Only .xls and .xlsx files can be uploaded as templates.
  • A template that refers to fields that do not exist for its report type still runs, but those cells print empty. Check new templates by generating a report before sharing them with users.

Warnings and Error Messages​

  • Required Fields: "This field is required." is shown when Name, Report Type or Output Format is empty.
  • Name Too Long: The name cannot be longer than 100 characters.
  • Description Too Long: The description cannot be longer than 500 characters.

User Tips and Best Practices​

  • Start From a Download: Download an existing or default template, change it and upload it as a new template instead of starting from an empty workbook.
  • Prefer User Defined: Users can then choose between PDF for sharing and Excel for further processing.
  • Use _Value for Calculations: Fields used in Excel formulas, sums or charts should be inserted with _Value.
  • Name Templates for Users: The template name is what users see in the Reports list and the name of the downloaded file; make it meaningful.