locked
mail merge loop RRS feed

  • Question

  • I have a Letter that list the address (that is the easy part) the Term that they signed up for. and the list all the classes. at the end of the letter there are a few paragraphs. the ony thing in common whith the classes and term is the person ID

    so the problem i am having is when i get to the classes how to loop unitl the next person.

    this is what i have so far

    {SET PID1 {MERGEFIELD "IDPerson"}}{SET PID2 {MERGEFIELD "IDPerson"}}{IF PID1=PID2 "{MERGEFIELD "Date_Header"}

    {address bock}

    Confirmation#: {MERGEFIELD Order_Number}

    this is where a table for the term info is

    your classes are:

    there is the tabel that need to loop

    "}{SET PID1 {MERGEFIELD "IDPerson"}}{Next}{SET PID2 {MERGEFIELD "IDPerson"}} {IF PID1 <> PID2 "then print out the end of the letter"

    Tuesday, February 12, 2013 6:23 PM

Answers

  • You can test the contents of a mergefield with field coding like:

    {IF{MERGEFIELD Term Registration} = "True" "True response" "False respinse"}

    Note: The field brace pairs (ie '{ }') for the above example are created in the body of the document via Ctrl-F9 (Cmd-F9 on a Mac) - you can't simply type them or copy & paste them from this message.


    Cheers
    Paul Edstein
    [MS MVP - Word]

    • Marked as answer by Rex Zhang Thursday, February 21, 2013 2:02 AM
    Wednesday, February 13, 2013 11:43 PM

All replies