Quote:
Originally Posted by ajh19742000
I am trying to produce a letter to send out to our clients that uses an IF statement. For example if a field says Art and Design and would like the merge to enter specific text. If the same field says Performing Arts then display different text. How is this done within the document?
|
Simply create two IF tests, coded along the lines of:
{IF{MERGEFIELD Subject}= "Art and Design" "Art and Design text"}
{IF{MERGEFIELD Subject}= "Performing Arts" "Performing Arts text"}
or:
{IF«Subject»= "Art and Design" "Art and Design text"}
{IF«Subject»= "Performing Arts" "Performing Arts text"}
Note: The field brace pairs (i.e. '{ }') for the above example are all 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 practical 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 'Insert Merge Field' dropdown. The spaces represented in the field construction are all required.
Quote:
Originally Posted by ajh19742000
Additionally can this be saved as a template?
|
For mailmerges, you use a mailmerge main document, not a template. Executing the merge produces whatever output (email, printout, or document) you require.