Use and If...Then...Else field that checks to see if the maiden field is
blank and if it is not, enters the maiden followed by a space, otherwise, it
inserts nothing.
{ IF { MERGEFIELD "maiden" } <> "" "{ MERGEFIELD "maiden" } " "" }

Signature
Please respond to the Newsgroup for the benefit of others who may be
interested. Questions sent directly to me will only be answered on a paid
consulting basis.
Hope this helps,
Doug Robbins - Word MVP
> I'm trying to merge a doc that has names, some with maiden names and some
> without. I want the merge to go first(space)maiden(space)last UNLESS
> there
> is no maiden name, in which case I only need ONE space.
>
> Any ideas?
S Cocke - 11 Feb 2005 17:31 GMT
Thanks. This may sound dense, but can you give me a step by step?
In the word doc, I have <<firstname>> <<maiden>> <<last>>
So, do I insert the IF...THEN function after I insert <<maiden>> or before?
Also, in the IF...THEN dialog box, where do I put the string that you gave
me? Do I enter If <<maiden>> is blank and then enter the string in the
"insert this text" box?
THANKS,
Shannon
> Use and If...Then...Else field that checks to see if the maiden field is
> blank and if it is not, enters the maiden followed by a space, otherwise, it
[quoted text clipped - 8 lines]
> >
> > Any ideas?
Doug Robbins - 11 Feb 2005 23:13 GMT
Type
MERGEFIELD "maiden"
then select it and press Ctrl + F9. You should now see
{ MERGEFIELD "maiden" }
Do this again so that you have
{ MERGEFIELD "maiden" }{ MERGEFIELD "maiden" }
Now add the IF, the <> "" " etc. so that you have
IF { MERGEFIELD "maiden" } <> "" "{ MERGEFIELD "maiden" } " ""
Don't forget the space after the second { MERGEFIELD "maiden" } before the
closing quote
Now select all of that and press Ctrl + F9 which should give you
{ IF { MERGEFIELD "maiden" } <> "" "{ MERGEFIELD "maiden" } " "" }
Now press Alt+F9 to toggle off the field codes and then execute your merge.

Signature
Please respond to the Newsgroup for the benefit of others who may be
interested. Questions sent directly to me will only be answered on a paid
consulting basis.
Hope this helps,
Doug Robbins - Word MVP
> Thanks. This may sound dense, but can you give me a step by step?
>
[quoted text clipped - 24 lines]
>> >
>> > Any ideas?
Karen:
Use the IF statement from the INSERT WORD FIELD menu after your MAIDEN
field:
{IF {MERGEFIELD Maiden} <> "" " " ""}
translates: If maiden is not blank, put a space here. Otherwise, put no
space.
Karen Hart
> I'm trying to merge a doc that has names, some with maiden names and some
> without. I want the merge to go first(space)maiden(space)last UNLESS
> there
> is no maiden name, in which case I only need ONE space.
>
> Any ideas?