I want to do a If-Then-Else statement in mailmerge such that if a condition
is true, 3 mailmerge fields are added to the document; otherwise, a
text-field (or, a single field) is added. I have tried &( )+ between the 3
fields (to "connect" them). Is there anyway to do it? (I keep getting the
second of the 3 I want to combine and add as the "else" part, which makes
sense...).
{IF {MAILMERGE evnttype = "OTSC" {MAILMERGE "date"} {MAILMERGE "time"}
{MAILMERGE "room"} "unscheduled" } }
TIA
st.
Doug Robbins - Word MVP - 01 Aug 2006 04:27 GMT
{IF {MAILMERGE evnttype} = "OTSC" "{MAILMERGE "date"} {MAILMERGE "time"}
{MAILMERGE "room"}" "unscheduled" } }

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
>I want to do a If-Then-Else statement in mailmerge such that if a condition
>is true, 3 mailmerge fields are added to the document; otherwise, a
[quoted text clipped - 9 lines]
>
> st.
zSplash - 01 Aug 2006 18:57 GMT
Works fine. Thanks, Doug. (So simple I'm kicking myself....)
st.
> {IF {MAILMERGE evnttype} = "OTSC" "{MAILMERGE "date"} {MAILMERGE "time"}
> {MAILMERGE "room"}" "unscheduled" } }
[quoted text clipped - 12 lines]
>>
>> st.
David Evans - 19 Aug 2006 15:52 GMT
Did anyone ever respond to this? I have the same issue...
>I want to do a If-Then-Else statement in mailmerge such that if a condition
>is true, 3 mailmerge fields are added to the document; otherwise, a
[quoted text clipped - 9 lines]
>
> st.
Peter Jamieson - 19 Aug 2006 16:44 GMT
Yes, Doug Robbins replied with
{IF {MAILMERGE evnttype} = "OTSC" "{MAILMERGE "date"} {MAILMERGE "time"}
{MAILMERGE "room"}" "unscheduled" } }
(all the {} need to be the special field braces you can enter using
ctrl-F9).
Peter Jamieson
> Did anyone ever respond to this? I have the same issue...
>
[quoted text clipped - 11 lines]
>>
>> st.