In Word 2007 how can I set up a repeating section for Mail Merge

You'll need a <<NextRecord>> field after each row of the data source EXCEPT THE LAST ONE ON THE PAGE.

If there is any way humanly possible to get that data source pre-processed to a temp file that has all of your data in one record it would help you a lot in the long term.


I've just seen this. Perhaps the product XpressDox would be something to look at. Although it might be overkill for just this one application. But if you have more like this, then it might be what you want. http://www.xpressdox.com (Disclosure: I am the developer of XpressDox).

The way I would recommend is that you use the Document per Repeated Item feature. You would approach it something like this:

Firstly, you would need to configure that data source in XpressDox. The web-site article Configure a data source gives step-by-step instructions on how to do this . In the code below I will assume that you have called the data source "MyDs", that the XpressDox name for the table is "Repeater" and that you have chosen the option that the entire data source is to be returned (i.e. not the option that the user must be able to choose a row).

Then (if you haven't already done it), type in the document (into Word), much as you have it in your example above.

Somewhere (anywhere, but probably at the top makes sense), put the XpressDox command:

«IncludeDataSourceData(MyDs)»

Where your example refers to the Merge Fields, replace the code in your example with:

«Repeater[$Number]/MergeField1», «Repeater[$Number]/MergeField2» «Repeater[$Number]/MergeField3»

Then save your document using the "Save Template" button in the XpressDox ribbon in Word, and then run the template. In the interview, leave the "Number" field empty, and then press OK. It should do what you want.

In practice, your column names will probably be something more useful than in the example. Bear in mind that the column names must conform to XML element naming rules, but otherwise they can be anything you want.