View Single Post
 
Old 03-16-2025, 07:34 PM
macropod's Avatar
macropod macropod is offline Windows 10 Office 2016
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Surely the simplest way would be to connect the documents to a data source containing all the required fields and, for each field, a record with whatever ouput text you want, then merge to a new document.

Still, if you're wedded to a VBA approach, you might find the macro titled Create Text Representations of Working Fields in the Mailmerge Tips & Tricks 'Sticky' thread at the top of the Mailmerge forum helpful. That code converts field codes to text representations of their content. See: https://www.msofficeforums.com/mail-...ps-tricks.html

PS: For mailmerges, you should be using mailmerge main documents, not templates.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote