Question : Doing a mail merge with section breaks using  a specific value

I am doing a mail merge with several thousand records for a "precinct walk"  I would like the unique values listed on the page based upon what precinct they are found in, (essentially, if a name switches from precinct A to precinct B I would like the mail merge to begin a new page and start to list the new records that are under precinct B.   Please advise, any help would be appreciated!

Answer : Doing a mail merge with section breaks using  a specific value

Mailmerge doesn't cater for one-to-many or hierarchical recordsets. I would put it high on the list of candidates for Word improvements.

There are a couple of techniques that do not use VBA.

If you have a limited number of subsidiary items, you can arrange your datasource so that each item has its own field.
e.g.

Forename, Surname, address1, address2, postcode, item1, item2, item3, item4,... itemN.

Another is to use Word Fields IF and MERGESEQ
http://support.microsoft.com/kb/294686/

Here are four approaches that use VBA.

This one uses VBA (in Access, but it could be in Word)  to create an individual document per customer.
http://www.experts-exchange.com/Applications/MS_Office/Word/Q_21090605.html

This talks about hooking into the  MailMergeAfterRecordMerge event to create a recordset for each customer's orders.
http://www.experts-exchange.com/Applications/MS_Office/Word/Q_21478463.html

Here VBA is used to split a single-table merge output into individual tables.
http://www.experts-exchange.com/Applications/MS_Office/Word/Q_21633674.html

This one is a Directory type merge to a Word table. The datasource is a flat file or the result of a one-to-many query. The merge fields are set up in the Word table to receive the 'many' data.

The MailMergeBeforeRecordMerge event is used to look for a change of data in the One table. It then starts a new document Section, saves the data from the one side fields using Word VBA techniques, and carries on until the next change.
http://www.experts-exchange.com/Applications/MS_Office/Word/Q_21669663.html
Random Solutions  
 
programming4us programming4us