WordMailMerge

Description

This activity perform mail merge operation between a DataTable and a Word document.

Mail Merge is a handy feature that incorporates data from both Microsoft Word and Microsoft Excel (represented in this activity with the DataTable) and allows you to create multiple documents at once, such as letters, saving you the time and effort of retyping the same letter over and over changing only a few words such as dates or names.

In order for the actiivty to work correctly, a Word template file and a DataTable (with the data to be inserted) must be provided, both correctly formatted. The result of the activity is a Word file containing the template repeated as many times as there are rows of the provided DataTable.

For more informations look at Microsoft tutorial which teaches you how to setup both Word file and Excel document to make mail merge possible.


Input

DataSource InArgument<DataTable> REQUIRED

The DataTable which contains all data to be replaced in the template. The table must have a column for each Merge Field in the template document.

To configure the merge easier, you can create the table in an Excel file and use the FromExcelToDataTable activity to convert it into a DataTable object that can be used in this activity.

Document InArgument<IFileValue> REQUIRED

The template Word document. This file must contain some Merge Fields to be replaced with DataTable fields.


Misc