View Single Post
 
Old 10-01-2018, 11:35 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,956
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

Quote:
Originally Posted by Louiseaf View Post
When building a nested statement, I understand to use ctrl+F9 to get the {} - can I just manually type the rest in it or are there other tricks I must use?
You could use the Ctrl-F9 approach to build the fields. However, if you already have your three IF tests, you can simply nest them. For example:

{IF{MERGEFIELD pvgdisclosure}= "PVG Both" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults and Children" ""}

and:

• There are no applicable conditions to this offer.

become:

{IF{MERGEFIELD pvgdisclosure}= "PVG Both" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults and Children" "• There are no applicable conditions to this offer."}

just by dragging '• There are no applicable conditions to this offer.' into the existing final field code. Similarly:

{IF{MERGEFIELD pvgdisclosure}= "PVG Adults" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults" ""}

and:

{IF{MERGEFIELD pvgdisclosure}= "PVG Both" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults and Children" "• There are no applicable conditions to this offer."}

become:

{IF{MERGEFIELD pvgdisclosure}= "PVG Adults" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults" "{IF{MERGEFIELD pvgdisclosure}= "PVG Both" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults and Children" "• There are no applicable conditions to this offer."}"}

just by dragging the combined field from the previous process into the preceding field code. And, by doing that one more time, you end up with:

{IF{MERGEFIELD pvgdisclosure}= "PVG Children" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to children" "{IF{MERGEFIELD pvgdisclosure}= "PVG Adults" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults" "{IF{MERGEFIELD pvgdisclosure}= "PVG Both" "• PVG: You successfully gain and maintain membership of the Protecting Vulnerable Groups scheme in relation to Adults and Children" "• There are no applicable conditions to this offer."}"}"}

The only (inconsequential) difference between that an what I suggested in post #2 is that I've left in some redundant double-quotes in this post.

Alternatively, you could use the macro found under Convert Text Representations of Fields to Working Fields in the Mailmerge Tips and Tricks 'Sticky' thread at the top of this forum (https://www.msofficeforums.com/mail-...ps-tricks.html) to convert the text representations of the field code in this post or post #2 into a working field code.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote