Don't use the address block! Use the individual fields. You can conditionally insert fields including country fields or address lines. e.g. (as there are only two countries involved)
{ IF { MERGEFIELD COUNTRY } <> "U*" "{ MERGEFIELD COUNTRY }" }
You can insert a paragraph break within the brackets if you wish to conditionally insert the line break before the field.
In the case of missing field data you can treat that in the same way
e.g.
{ MERGEFIELD FIRSTNAME } { MERGEFIELD LASTNAME }{ IF { MERGEFIELD COMPANY } <> "" "¶
{ MERGEFIELD COMPANY }" }{ IF { MERGEFIELD ADDRESS1 } <> "" "¶
{ MERGEFIELD ADDRESS1 }" }{ IF { MERGEFIELD ADDRESS2 } <> "" "¶
{ MERGEFIELD ADDRESS2 }" }¶
{ MERGEFIELD ADDRESS3 }¶ etc
¶ = Press the enter key.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
|