Results 1 to 2 of 2
  1. #1
    New Lounger
    Join Date
    Dec 2013
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Mailmerge compare / condition rule

    Hi

    I have a mailmerge document with the following lines:
    { MERGEFIELD TableStart:LineItem \* MERGEFORMAT }{ MERGEFIELD Description \* MERGEFORMAT }

    { MERGEFIELD TableEnd:LineItem \* MERGEFORMAT }

    Within the data I have a field called 'code' whereby I only want to include items with a certain code. How would I do this and where would I place the correct code within the above preset format?

    Thanks in advance.

  2. #2
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    Hi beckyb,

    Your field code suggests you're using a 3rd-party Addin, not just Word's own mailmerge tools. In such cases, it's hard to know how much control you have over their processing. That said, you may be able to skip the non-conforming records by adding a SKIPIF field before the Description mergefield; something along the lines of:
    {SKIPIF {MERGEFIELD Code} <> 12345}
    where 'Code' is the name of the field containing your codes and the 12345 is the code value you want to limit the output to.
    Cheers,

    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
  •