Create Microsoft Word templates for Virtus Flow
In this article we learned how to upload a DOCX file to Virtus Flow.
But how can you create a docx file compatible with Virtus Flow?
Open a Word file of your choice (.docx) and for every section that you want Virtus Flow to automatically generate content, add a placeholder. To add a placeholder simply add {placeholder_name} changing "placeholder name" with a label that can be associated with the relative content. Virtus Flow uses the content of the brackets as the designatory field of our content.
Example: {field1}.
| NOTE: Do not use special characters, accents, or SPACES in the placeholder definition. If you do so, when uploading the document in Virtus Flow you'll see an error parsing message. |
The fields are automatically identified once the document has been uploaded to Virtus Flow.
Recursive Workflows, List, or Table:
You can create a list / table by inserting the following syntax {#list1} {fieldA} {fieldB} {/list1}. The field names may only contain letters, numbers and underscores.
| NOTE: For a LIST you much use a recursive workflow or a table type question to associate it with, for the FIELDS you must choose a Child Workflow that it is associated with. |
In other words, you can create an Array, use the following syntax: {#placeholder} and {/placeholder} where all the values (E.g. {fieldA}{fieldB} shown below) in the array between the two brackets will be different rows or columns of the document. You can also add Conditions like this one {#placeholder.length>0} to show the field only when is not null. Also note that the placeholders can be used to add text or to print the yes/no answers given.
Below is how you will configure it in the workflow.
The result will look like the following. As you can see, the placeholders also work for adding text or adding the yes/no answers chosen.
| NOTE: Character color and font need to be the same in order for it to work correctly. Also, spaces inside the curly braces for the {placeholders} are not recognized. |
When using the DOCX field to generate the document, you can also rename the file inside the workflow. This can be done by choosing the DOCX field in the FILENAME section. You can add whatever name you choose as well as use dynamic fields that will change according to the options filled out in the workflow.
To view a step-by-step of this process, please view the following video:
Comments
0 comments
Article is closed for comments.