View Single Post
 
Old 08-03-2015, 09:06 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
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

Not using a Mac, I don't know what the "other placeholders" tab is - there isn't one of that name in Word 2010, for example.

That said, it seems you want to conditionally output some content only when a particular field has some content. Since you're using a Mac, you can't use the mergefield \b and \f swtiches for that purpose. Instead you need to use an IF field to perform a test.

Suppose, for example, you're merging data for clients and your data source contains a field for their middle initials, named 'Initials'. In that case you might use a field as follows to only output a space after the 'Initials' field if it actually has some content:
{IF{MERGEFIELD Initials}<> "" "{MERGEFIELD Initials} "}
or:
{IF«Initials»<> "" "«Initials» "}

Note: The field brace pairs (i.e. '{ }') for the above example are all created in the document itself, via Cmd-F9 (Ctrl-F9 on a PC); you can't simply type them or copy & paste them from this message. Nor is it practicable to add them via any of the standard Word dialogues. Likewise, you can't type or copy & paste the chevrons (i.e. '« »') - they're part of the actual mergefields, which you can insert from the mailmerge toolbar. The spaces represented in the field construction are all required.

This is all discussed in my Mailmerge Tips & Tricks Sticky thread at the top of this forum: https://www.msofficeforums.com/mail-...ps-tricks.html
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote