PROCESIO
OverviewPlatform ActionsIntegrations & DemosMarketplaceCustom ActionsDeveloperโ€™s Guide

Word Mail Merge

Fills the mail merge fields of a Word (.docx) document with your values, and can save the result as PDF.

Word Mail Merge takes a Word document that contains mail merge fields (for example ยซFirstNameยป) and replaces each field with a value from your process. Use it to produce letters, contracts or certificates from a template that was designed in Word.

Add the action

In the Process Designer toolbox, open Documents and pick Word Mail Merge (or type Word Mail Merge in the search box).

The Word Mail Merge action properties: Word File, Completed Word File, the Word Mail Merge card and Make Document PDF

Inputs and outputs

FieldDirectionTypeRequiredWhat to put / what you get
Word FileInputFileYesThe template, a .docx file with mail merge fields.
Word Mail Parameters (in the Word Mail Merge card)InputPairs of field name and valueYesOne row per field: on the left the field name exactly as in the document, on the right a fixed value or a process variable.
Make Document PDFInputBoolean (true/false)NoTick it to get a PDF instead of a Word file.
Completed Word FileOutputFileYesThe filled document. It keeps the template's name, with .pdf instead of .docx when Make Document PDF is ticked.

Prepare the template

In Word, open Mailings โ€บ Insert Merge Field (or Insert โ€บ Quick Parts โ€บ Field โ€บ MergeField) and give each field a name without spaces, for example FirstName or Order_Id. The fields can be in the body, in headers and in footers.

Example

Template letter.docx: Dear ยซFirstNameยป, your order ยซOrderIdยป ships on ยซShipDateยป. ยซUnmappedยป|ยซfirstnameยป

Word Mail Parameters FirstName โ†’ Ana, OrderId โ†’ 1042, ShipDate โ†’ 12 Nov 2026 โ†’ Completed Word File letter.docx: Dear Ana, your order 1042 ships on 12 Nov 2026. |

CaseResult
A field that has no row (ยซUnmappedยป)Replaced with nothing
A row whose name differs only in case (firstname vs FirstName)Not matched, the field is replaced with nothing
Two rows with the same field nameThe step fails: "Duplicate destination field names found: โ€ฆ"
A template named hello.txtThe step fails: "Input error: File extension should be '.docx', found => .txt"
A real Word template with Make Document PDF tickedCompleted Word File is a PDF, mm.docx becomes mm.pdf

Good to know

  • Field names are case-sensitive and must match exactly. A field that gets no value is removed from the document, so a typo shows up as an empty spot, not as an error.
  • Every merge field is replaced by plain text. The value does not keep the formatting switches of the field (number or date formats), so format dates and numbers in your process before the merge.
  • Values are inserted as text: line breaks, HTML and images in a value are not rendered.
  • Only .docx files are supported. Save older .doc templates as .docx first.
  • A file that is not a valid Word document fails with "The input file appears to be corrupted or is not a valid .docx file."
  • To build documents from a template designed in PROCESIO instead of Word, use Generate Document.

On this page