Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Oct 2014
    Thanked 0 Times in 0 Posts

    Possible to have extra text added to a mail merge, if a condition is met?


    I have one master letter that goes to every state, but certain states require that I add additional language to the master letter.

    So intead of creating serveral copies of the letter that will need to be updated if anything ever changes, I'd like to add a formula that says if State = WA, then add this text.

    I probably have 15 states that require specific language to be added to our master letter - some of them are pages long...

    Is this even possible?

    Please help!!!

  2. #2
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Sun Prairie, Wisconsin, Wisconsin, USA
    Thanked 128 Times in 123 Posts
    Yes. This is done with an IF field that tests for the contents a merge field. The link in the previous sentence includes an example using a mergefield for the test. Here is Microsoft's reference on the IF Field.
    Last edited by Charles Kenyon; 2014-12-11 at 16:21.
    Charles Kyle Kenyon
    Madison, Wisconsin

  3. #3
    Super Moderator macropod's Avatar
    Join Date
    May 2002
    Canberra, Australian Capital Territory, Australia
    Thanked 465 Times in 382 Posts
    Adding conditional text to a mailmerge is quite easy. You can use the 'If...Then...Else...' dialogue from the Rules dropdown, or you can encode the fields manually. For example:
    {IF{MERGEFIELD STATE}= "AK" "Text for AK"}
    {IF{MERGEFIELD STATE}= "WA" "Text for WA"}
    etc., or:
    {IF«STATE»= "AK" "Text for AK"}
    {IF«STATE»= "WA" "Text for WA"}

    Note: The field brace pairs (i.e. '{ }') for the above examples are created in the document itself, via Ctrl-F9 (Cmd-F9 on a Mac); 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.

    Paul Edstein
    [MS MVP - Word]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts