Creating a template

Prev Next

Follow these steps to add a template, import the corresponding input parameters and edit them, if necessary.

Prerequisites

Steps

  1. In the Activities section, select the Templates tile.

    Activities section with Templates tile

    The dox42 Templates dialog opens.

    Skip step 3 and 4 if your template already exists.

  2. Select the New button to add a new template.

    dox42 Templates dialog

  3. Enter a descriptive Code name, preferably the original name of your Word template, e.g. “INVOICE”.

  4. Go to SharePoint, locate the template you want to use for document generation and copy its SharePoint file path. To do so, click the three dots next to the template’s file name, select “Details” and then select the “copy path” icon in the More details window.

    Document management interface showing job quote files and recent activity details.

    Copy file path icon in SharePoint

    Important

    Always use a public file path instead of a local one and make sure your dox42 Online has access to it.

  5. Go back to where you left Business Central. In the Server Path text field, enter the SharePoint path, where your template is stored.

    Template’s server path in dox42 Templates dialog

  6. Now, define the input parameters for the selected template. We recommend importing them from your template’s data map instead of creating them manually. This helps to avoid errors. Follow these steps to do so:

    1. Select the Import Input Parameters from DataMap button in the header.

      List of templates with highlighted input parameters for invoice processing in dox42.

      Import Input Parameters from DataMap button

    2. From the file explorer, import a data map in the .dm file format.

    3. You can edit the properties of the input parameters for the selected template and also create new parameters. Select the Input Parameters button in the header.

      Input Parameters button

      The dox42 Input Parameters dialog opens.

      Input parameters for dox42 in Dynamics 365 Business Central interface.

      dox42 Input Parameters dialog

    4. Optional, edit the input parameter list according to this field description:

      Field

      Description

      dox42 Name

      Name of the input parameter.

      Important

      The value must match the name of the input parameter in your template.

      Data Type

      Possible data types: Bool, Text, Integer, Decimal, Field reference, Code, Date, Time, Date/Time, Special, Listing

      Default Caption

      Display name of the input parameter on the Request Page.

      Show on Request Page

      If the field is checked, this input parameter will be displayed on the Request Page.

      Table ID

      For field reference data type only:

      The number of the table within Business Central.

      Field ID

      For field reference data type only:

      The number of the field within Business Central.

      Table Name

      For field reference data type only (automatically filled):

      The Name of the selected table.

      Field Name

      For field reference data type only (automatically filled):

      The Name of the selected field.

      Special Option

      Allows you to create additional input parameters, for use in a template. Possible data: client, user, language code, execution time, work date.

      Default Value

      Allows you to store a default value for the input parameter.

      Use Default Value

      Specifies whether the stored default value will be preset on the Input Parameter page.

  7. Use the arrow buttons at the top to exit the dialogs.

Result

You have created a template for an output generation.  

Next step

Create a document configuration