Registering reports

How to register Office reports in Vertec

Operating mode

Cloud Suite

|

ON-PREMISES

Modules

Services & CRM

Budget & Phases

Purchases

Resource Planning

Business Intelligence

Created: 23.04.2007
Updated: 15.05.2025 | New page for multilingual document templates with version 6.8.

This article explains how to register Office Reports (Word, Excel, PDF).

A report must be registered before it can be accessed from the Print menu in Vertec. To register a report, go to the folder Settings > Reports & Scripts > Report templates and select New > Office report.

Name

Name under which the report appears in the Print menu.

Active

Only active reports appear in the menus. If you do not want to use a report, you can simply deactivate it here.

Grouping/Single index

With many different reports, the print menu for a particular item can quickly become confusing. To solve this problem, reports can be grouped and sorted during registration. This allows you to combine several reports into a group, which is then separated from the rest of the reports by a hyphen.

Grouping is activated by entering a group number in the Grouping field on the report. All reports which have the same group number are combined into a group in the menu. The different groups are shown in the order of their group number.

By default, the reports within a group are again sorted alphabetically. If a different sorting method is desired, this can be done by inserting numbers in the Single index field.

Classes

Specifies for which objects in Vertec the report is registered (e.g. projects or addresses). The report appears there in the Print menu.

Condition

You can define via a display condition whether or not the report should be shown in the Print menu.
You need to use an OCL expression for this. Click on the button with the three dots to open the OCL expression editor.

The result of this expression must return a Boolean Yes/No value. If the condition is met, the report appears in the Print menu; otherwise, it doesn't. For list reports, the report is only shown if the condition is met for all entries in the list.

Output format

For the output format, you have the choice between Word, Excel and PDF.

  • Word and PDF always use the Word template
  • Excel always uses the Excel template

If the selected output format does not match the registered templates – e.g. Excel is selected if only one Word template is stored – an error message appears.

Single report/List report

Specifies whether the report can be run on a single object or on a list of objects of the specified data type (class).

Outlook App email template Specifies whether the report can be used as an email template in the Outlook App.
Automatic saving
Filename

Field in System Settings > Document storage = Internal

You must enter a file name if you want to open, edit, and save documents stored on an activity (see below).

Path

Field in System Settings > Document storage = Filesystem or DMS

Path to store the report document. The value %dokpfad% uses the document path (value of the “DocPath” attribute) of the object on which the report is run.

In addition to fixed texts, you can use OCL expressions (enclosed with %) that are used when printing the report. Within the placeholders, you can use any OCL expression based on the current object of the report, e.g. %dokpfad%\%nummer% on an invoice report.

If the restricted filesystem access option is enabled in the Vertec.ini configuration file (default for Cloud Suite customers), the reports behave as follows:

  • Reports are stored on the client side
  • Reports are not saved in the Web App
  • An error message occurs when a report is run with a configured storage path via Web App. In this case, it is not possible to save a document or create an activity.
Subject

Document subject. You can use an OCL expression here, enclosed with %.

You can still adjust the subject on the print dialog if it is shown (see next point).

In the document, the subject is a context variable.

You can also use the subject in the path (see above). The expression is %subject%.

In addition, the subject is used as the title of the activity if one is created (see below).

Show dialog

If Yes, a print dialog is shown before running the report, in which you can change the comment, remark and other options, if required.

Create activity

If Yes, executing the report creates an activity, on which the document is saved. It opens in the relevant editor and can be edited directly.

With System Settings > Document storage > Internal, the created activity is automatically shown in a new tab. The opened document is shown in the corresponding editor, where it can be edited directly further. And the button below the document preview is called Stop editing. A file name must be entered for this. You can find all information about documents on activities here. With Vertec 6.7.0.7, this behavior was adjusted for PDFs: They are only shown, but are not able to be edited.

Link on main object

The activity is linked to the object from which it is started.

Link on address

The activity is associated with the address to which the document is sent.

Activity type

Here, you can assign an activity type to the generated activity.

Report definition

Office reports consist of a combination of a Word or Excel template for the layout and a report definition in the form of Python code for the content. For more information, see the Office reports (Word, Excel, PDF).

The Report definition page contains the Python code for the specified template.

The internal name refers to the code supplied by Vertec. This is shown under the Built-in tab.

Under the Customization tab, you can overwrite the supplied code. As soon as code is available under Customization, only this code is valid. If you want to change something, you have to copy the complete code from the Built-in tab and change it under the Customization tab.

Customer-generated or commissioned Office reports do not have built-in code or internal names. Instead, the code is inserted directly in the Customization field.

If extended user rights are required in the Python code, e.g. for SQL access, the Extended rights checkmark must be set below the report definition.

Document templates

On the Document templates page, the appropriate template document is selected. For Word reports, this is a Word document with the file extension .docx; for Excel reports, an Excel document with the file extension .xlsx. As the Excel and Word templates share the code base, both can also be registered in the same registration at the same time.

Checkboxes

When you check the checkbox Activate translation to project language:

  • Reports that are executed on individual objects and have a defined relationship to a project (e.g. invoices or project evaluations) are translated into this project language (or all labels provided with translation).
  • Reports that run on multiple objects (list reports) are translated into the current Vertec interface language. The translations of the reports into the various languages are done by the Vertec translation mechanism.

By activating the checkbox Own template per language, templates can be stored in several languages. See below.

Download

You can download and edit templates with the Download button.

Upload

You can upload a customized template with the Upload button.

This process also copies the built-in report code and pastes it into the Customization tab if it is still empty (see Report definition section).

Reset/Delete

If the customer-specific template overwrites or customizes an existing Vertec default report, the button is named Reset. This enables you to remove the custom template and to restore the default report.

Resetting not only resets the template to the default, but also removes the relevant report code from the Customization tab. Therefore, if you still require the customized code, you should copy it out before resetting.

When you register a new, customized template, it is shown in black font. With the Delete button, you can remove the template again.

  • The font is black if it is a default template supplied by Vertec.
  • The font is green if it is a customer-specific template.

Multilingual templates

When you activate the checkbox Own template per language, the following list appears:

By selecting a language, a new row is created. Only one template can be defined per language.

Template

Selects the appropriate template document. For Word reports, this is a Word document with the file extension .docx, for Excel reports an Excel document with the file extension .xlsx.

Language
A template can be specified for each language defined in the system. When printing, the language is automatically selected according to the following criteria:
  • The language of the associated project.
  • Special case activity: If no project is assigned, the language of the assigned address entry is taken into account.
  • For entries to which no project can be assigned, an attempt is made to assign the member Language of the entry.
  • If no language was found with all of these variants, the language of the interface is used.

If no template is defined for a language, the first template in the list is taken.

Jargon

Project, case, everyone.

Here you can specify for which jargon (case or project language) the template should be used.

If All is selected, only the language is taken into account, regardless of the jargon.

Name for automatic saving

If the system setting is set to Filesystem or DMS, the storage path and document name are compiled as follows:

The Path field on the main page of the report registration is used for all templates, if something has been entered there. It can contain both a path and a file name:

  • This will now include the name for automatic saving of each template, if something is entered there. This can also contain both path and file name.
  • This allows you to combine the two fields. The important thing is to make sure that the two fields together give a valid path and file name.

With internal document storage:

  • The File name field on the main page of the report registration is used for all templates, if something is entered there. If a path is specified, it is simply filtered out when storing the document internally.
  • The name for automatic saving of each template is now appended to it, if something is specified there.
  • The two fields are combined. You must ensure that the combination results in a valid file name.

This means:

  • If you want to save all reports the same (e.g. with a dynamic OCL expression, see below), the File name field suffices.
  • If you want to save the documents differently in the various languages, this is stored on the template under Name for automatic saving.

In addition to fixed texts, you can also use OCL expressions (framed with %) which are evaluated when the report is created.

Within the placeholders, any OCL expression can be used, starting from the current object on which the document is created.

In addition, the following OCL variables are available on reports:

  • %docpath%: Enter the document path of the object on which the report is run. If stored internally, the path is filtered out.
  • %subject%: Contains the subject, which is either defined in the Subject field on the report registration or is entered ad hoc in the report dialog (Show dialog is checked).

Examples of OCL expressions:

  • On an invoice, the invoice number: %nummer%.
  • The date in the format YYYYMMDD: %date.formatdatetime('yymmdd')%.

 

Netherlands

United Kingdom