Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Harry Weeds
 
Posts: n/a
Default Correct spacing for blank fields in name mailmerge

How do you keep Word from putting an extra space between fields that are on
the same line when there is a field that may be blank for some records - a
middle initial field, for example. Some records will have middle initials
resulting in correct spacing between the various fields, but when the middle
initial field is empty the spacing between the first and last name will be
wrong. Thank you for your help.
  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Charles Kenyon
 
Posts: n/a
Default Correct spacing for blank fields in name mailmerge

You use an IF field to test for any contents in the may-be-blank field. If
the field is not blank, insert the field and a space, if it is blank, insert
nothing.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide

See also the MVP FAQ: http://word.mvps.org/FAQs/ which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.


"Harry Weeds" wrote in message
...
How do you keep Word from putting an extra space between fields that are
on
the same line when there is a field that may be blank for some records - a
middle initial field, for example. Some records will have middle initials
resulting in correct spacing between the various fields, but when the
middle
initial field is empty the spacing between the first and last name will be
wrong. Thank you for your help.



  #3   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Graham Mayor
 
Posts: n/a
Default Correct spacing for blank fields in name mailmerge

{Mergefield First_Name}{IF {Mergefield Initial} "" " {Mergefield
Initial}"} {Mergefield Last_Name}

Note the space at
" {Mergefield Initial}"}
and before
{Mergefield Last_Name}
No space after
{Mergefield First_Name}
--

Graham Mayor - Word MVP

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


Harry Weeds wrote:
How do you keep Word from putting an extra space between fields that
are on the same line when there is a field that may be blank for some
records - a middle initial field, for example. Some records will
have middle initials resulting in correct spacing between the various
fields, but when the middle initial field is empty the spacing
between the first and last name will be wrong. Thank you for your
help.



  #4   Report Post  
Posted to microsoft.public.word.mailmerge.fields
RRR_News
 
Posts: n/a
Default Correct spacing for blank fields in name mailmerge

Harry,
This also works for me:
{ Mergefield First_Name }{ Mergefield Middle_Name \b " " } { Mergefield
Last_Name }

Using the "before" (\b) switch. And using the spacing that Graham has stated
already.

For prefixes such as Mr., Mrs., Ms., I have a column named "Prefix". The line is
set up lile this:

{ Mergefield Prefix \f " " }{ Mergefield First_Name}{Middle_Name \b " " } {
Mergefield Last_Name }

Using the "after" (\f) switch. Also using the spacing that Graham has stated
already.

--
Have A Good Day
Rich/rerat

Add MS to your News Reader: news://msnews.microsoft.com
(RRR News) message rule
Previous Text Snipped to Save Bandwidth When Appropriate


"Graham Mayor" wrote in message
...
{Mergefield First_Name}{IF {Mergefield Initial} "" " {Mergefield
Initial}"} {Mergefield Last_Name}

Note the space at
" {Mergefield Initial}"}
and before
{Mergefield Last_Name}
No space after
{Mergefield First_Name}
--

Graham Mayor - Word MVP

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


Harry Weeds wrote:
How do you keep Word from putting an extra space between fields that
are on the same line when there is a field that may be blank for some
records - a middle initial field, for example. Some records will
have middle initials resulting in correct spacing between the various
fields, but when the middle initial field is empty the spacing
between the first and last name will be wrong. Thank you for your
help.



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Programmatically inserting mailmerge fields into a document [email protected] Mailmerge 0 October 20th 05 06:44 PM
Mailmerge vs. form fields Candace Mailmerge 1 September 8th 05 07:14 PM
How to use access query computed fields in Word mailmerge Rey Mailmerge 5 June 23rd 05 06:26 PM
How do I use a form then mailmerge without losing the form fields Someone who's stuck Mailmerge 1 June 23rd 05 10:01 AM
Using MAILMERGE fields within HYPERLINK fields for Merge to Email Mark V Mailmerge 2 December 4th 04 04:01 PM


All times are GMT +1. The time now is 06:55 PM.

Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.
Copyright 2004-2023 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"