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 / December 2003

Tip: Looking for answers? Try searching our database.

merging different name formats

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mike S - 16 Dec 2003 20:13 GMT
In our Outlook 2003 data we have three different name
formats, the data is in the following fields.
1. John Doe: first= John, last= Doe
2. John and Mary Doe: first= John, Spouse= Mary, Last= Doe
3. John Doe and Mary Smith: first= John, last= Doe,
spouse= Mary Smith

We are trying to figure out how to construct a merge
field so letters and envelopes will print all these names
correctly ie:
John Doe, John and Mary Doe, John Doe and Mary Smith.
Graham Mayor - 17 Dec 2003 07:35 GMT
1 & 2 are easy to arrange using condtional fields, but I see no way of
handling 3 also, unless you create a new Outlook field and separate the
spouse's surname and forename in the data file.

Signature

<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
    Graham Mayor -  Word MVP
      E-mail gmayor@mvps.org
  Web site www.gmayor.com
 Word MVP web site www.mvps.org/word
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>

> In our Outlook 2003 data we have three different name
> formats, the data is in the following fields.
[quoted text clipped - 7 lines]
> correctly ie:
> John Doe, John and Mary Doe, John Doe and Mary Smith.
Peter Jamieson - 17 Dec 2003 11:18 GMT
Thought I'd answered this one...

As long as the Spouse names follow a certain pattern, e.g.
a. In your case (2) there is only ever one name in spouse, e.g. never "Anne
Marie"
b. In your case (3) there is always more than one name
c. the characters in the names are in alphabets that have
lowercase/uppercase versions of the letters

you can try the following:

{ MERGEFIELD first } { IF "{ MERGEFIELD spouse }" = ""
"{ MERGEFIELD last }"
"{ IF { QUOTE { MERGEFIELD spouse \*lower } \*firstcap } = { QUOTE {
MERGEFIELD spouse \*lower } \*caps }
"and { MERGEFIELD spouse } { MERGEFIELD last }"
"{ MERGEFIELD last } and { MERGEFIELD spouse }" }" }

If the names are also always capitalised the same way, i.e. all lowercase
except all initial caps, you can simplify that to

{ MERGEFIELD first } { IF "{ MERGEFIELD spouse }" = ""
"{ MERGEFIELD last }"
"{ IF { QUOTE { MERGEFIELD spouse \*lower } \*firstcap } = { MERGEFIELD
spouse }
"and { MERGEFIELD spouse } { MERGEFIELD last }"
"{ MERGEFIELD last } and { MERGEFIELD spouse }" }" }

--
Peter Jamieson - Word MVP

> In our Outlook 2003 data we have three different name
> formats, the data is in the following fields.
[quoted text clipped - 7 lines]
> correctly ie:
> John Doe, John and Mary Doe, John Doe and Mary Smith.
 
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.