Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Mailmerge and Fax / November 2004

Tip: Looking for answers? Try searching our database.

Eliminating spaces in merged documnents

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
johnsoned - 29 Oct 2004 12:55 GMT
I am merging names and addresses from an excel document to several different
word documents. I set up the excel file with a separate field for middle
name/initial. When a name without a middle name/initial prints there are two
spaces between the first and last name. What could be done to fix this other
than getting rid of the middle name/initial field and adding this information
to the first name field.
Graham Mayor - 29 Oct 2004 13:16 GMT
Use a conditional field to place the initial and its leading space when
there is content eg

{IF {Mergefield Initial} <> "" " {Mergefield Initial}"}

Signature

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor -  Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

> I am merging names and addresses from an excel document to several
> different word documents. I set up the excel file with a separate
[quoted text clipped - 3 lines]
> middle name/initial field and adding this information to the first
> name field.
johnsoned - 30 Oct 2004 02:55 GMT
If I knew what I was doing, the answer you gave me would probably work, but I
must be missing something. When I edit the field-code, instead of the middle
name or just a space, I get   {IF G.<> "" "G."} or {IF<>"" " "}  where the
middle name/initial should be when I merge the Word document. Can you tell me
what am I doing wrong?

> I am merging names and addresses from an excel document to several different
> word documents. I set up the excel file with a separate field for middle
> name/initial. When a name without a middle name/initial prints there are two
> spaces between the first and last name. What could be done to fix this other
> than getting rid of the middle name/initial field and adding this information
> to the first name field.
Greg Maxey - 30 Oct 2004 03:14 GMT
It looks like you just need to toggle field code display (ALT+F9)

Signature

Greg Maxey/Word MVP
A Peer in Peer to Peer Support

> If I knew what I was doing, the answer you gave me would probably
> work, but I must be missing something. When I edit the field-code,
[quoted text clipped - 9 lines]
>> middle name/initial field and adding this information to the first
>> name field.
Graham Mayor - 30 Oct 2004 09:09 GMT
I believe Greg has identified half the problem. the other half is that you
may have typed {} from the keyboard instead of using CTRL+F9 to set the
field boundaries. If you use CTRL+F9 for each pair and type the rest
directly (substituting your data field names as appropriate) you should find
that it works. Don't forget to include the space between the speech marks of
the result.

Signature

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor -  Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

> If I knew what I was doing, the answer you gave me would probably
> work, but I must be missing something. When I edit the field-code,
[quoted text clipped - 9 lines]
>> middle name/initial field and adding this information to the first
>> name field.
johnsoned - 30 Oct 2004 15:13 GMT
I swear that I have followed the instructions you gave me to the letter. I
didn't know about using CTRL+F9 to make each set of brackets. So I was sure
that everything would fall into place once I did that, but after typing the
correct information between each set of brackets, I still have my original
problem (two spaces between the first name and last name when no middle
name/initial is present). I even tried eliminating all of the spaces within
the brackets for the middle name field code to no avail.    

> I believe Greg has identified half the problem. the other half is that you
> may have typed {} from the keyboard instead of using CTRL+F9 to set the
[quoted text clipped - 16 lines]
> >> middle name/initial field and adding this information to the first
> >> name field.
Graham Mayor - 30 Oct 2004 15:24 GMT
If you followed the instructions to the letter, you will have no space
unless the space is included in the data itself. However, let's include the
fields on either side for the sake of clarification:

{Mergefield First_Name}{IF {Mergefield Initial} <> "" " {Mergefield
Initial}"} {Mergefield Last_Name}
or
{Mergefield First_Name}no space{IF {Mergefield Initial} <> ""
"space{Mergefield Initial}"}space{Mergefield Last_Name}

Signature

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor -  Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

> I swear that I have followed the instructions you gave me to the
> letter. I didn't know about using CTRL+F9 to make each set of
[quoted text clipped - 35 lines]
>>>> middle name/initial field and adding this information to the first
>>>> name field.
johnsoned - 01 Nov 2004 03:58 GMT
Thank you for your patience, I finally got the result I was looking for.

> If you followed the instructions to the letter, you will have no space
> unless the space is included in the data itself. However, let's include the
[quoted text clipped - 45 lines]
> >>>> middle name/initial field and adding this information to the first
> >>>> name field.
Graham Mayor - 01 Nov 2004 08:48 GMT
That's a relief ;)

Signature

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor -  Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

> Thank you for your patience, I finally got the result I was looking
> for.
[quoted text clipped - 58 lines]
>>>>>> getting rid of the middle name/initial field and adding this
>>>>>> information to the first name field.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.