Skip to Main Content

Using Docx Templates in OnTask Workflows

OnTask’s new “Generate Document” feature makes it easy to populate Docx templates with data collected from user input. This new feature supports all Docx editors, such as Google Docs, Word, and more. 

Simply define the text you’d like to populate within your documents, convert them to variables, and start collecting. Here’s how:

How to Integrate Docx Forms

1.  From your template library, select the button reading, “I’d like to create a new workflow or web form from scratch.” 

2.  Next, select the group where you would like your new template stored from the dropdown menu, and click “Start from scratch”. You can either enter a name for your new workflow template of press skip to enter one later.

3.  Next, you’ll want to open the document you’d like to convert and determine what text from your document you’d like to be populated from the workflow.

4.  Any text you’d like populated through OnTask must be converted to variables. Doing this is easy, simply add {%(text)%} around the lines of text you’d like converted.

For example, if you’d like to pull in the “Project Name”, simply type {%Project Name%} in its place to make the text recognizable to OnTask.

5.  Once you’ve identified and converted your text fields to variables, download your Docx file to your computer.

6.  Next, go back into OnTask’s workflow builder and select “Insert first task”, and then select “web form”.

7.  Next, you’ll need to edit this task so that you may collect an input for each variable in the document. To do this, go into the form fields area, and select your field type. You’ll also want to make sure to add a field label.

If we were using the “Proposal Date” as our example, we would select “Single-line text and the field type” and simply use “Proposal Date” as the field label, which will be automatically used in your property name.

8.  Now that you’ve added in your web form fields, it’s time to add another step to your workflow. Insert a new task, and select “Generate document from form data” under the document processing category.

9.  Next, you’ll be prompted to upload your Docx file. Once uploaded, you’ll be required to give your document a name.

10.  Underneath your document name, you’ll see the data mapping selection. OnTask will automatically scan your document for fields (for example, {%Project Name%} and automatically list these options for you to select. Choose the corresponding variables for your fields.

11. Once that’s done, return to your workflow. From here, you can add any other steps you’d like in your workflow such as a fill & sign task or route for approval.