Expand Minimize

How to: Customize report templates for PDF and DOCX

Besides format HTML, SPCAF can also create reports in the formats PDF and DOCX as a result of an analysis. Sometimes it is required that the layout of these reports meet the corporate design. To achieve this the report template for PDF and DOCX reports can be customized (starting with version v6.5).

How it works

SPCAF uses for PDF and DOCX reports a Word document template (.dotx). During report creation, this template file is loaded and the report content is inserted into that document template. The final document is then saved directly as DOCX or converted to PDF.

The default template "ReportTemplate.dotx" can be downloaded here: ReportTemplate.dotx

What can be customized

The report content does not contain any styles. The layout of the final report is defined by the Word styles in the template file. Changing these styles in the template file impacts the layout of the final report.

You can customize:

  • First page of the report (entry page with title, logo etc.)
  • Header and Footer of the report
  • Styles of headlines, content, and lists
  • Styles of tables
How to load customized template

The SPCAF engine searches during report creation in several folders for an existing file with name "ReportTemplate.dotx".

You can place the file "ReportTemplate.dotx:"

  1. In the folder "SPCAF" inside the LocalAppData folder of the user (typically C:\Users\[username]\AppData\Local\SPCAF). The report template is then loaded only for that user.
  2. In the installation folder of SPCAF. The report template is then loaded for all users (except when there is template in the user's AppData folder, see 1.)
Disclaimer: The views and opinions expressed in this documentation and in SPCAF do not necessarily reflect the opinions and recommendations of Microsoft or any member of Microsoft. SPCAF and RENCORE are registered trademarks of Rencore. All other trademarks, service marks, collective marks, copyrights, registered names, and marks used or cited by this documentation are the property of their respective owners.