Ok, I cannot seem to figure this out or at least get it to work right. What I
am doing is trying to bring a list customers from an excel sheet and have
their lastname print on it with the proper salutation for them in a Word
document. In the excel sheet, the columns are labeled as lastname then
firstname then sex. When I use the mailmerge option, i get either the sex
and lastname(F Martinez) or firstname lastname (Emilia Martinez). I want it
to show Ms. Martinez.. I cannot do a substitutionon the Excel sheet. If I
could, the problem would have been solved along time ago. I am a little
frustrated by it. I have been working on it for 2 days now. I need the Word
document to read " Dear Ms. Martinez,".
Sorry for the whining. I am just aggravated at it now.
Doug Robbins - Word MVP - 03 Mar 2006 05:16 GMT
Use an If...then...Else... field
{ IF { MERGEFIELD sex } = "F" "Ms." Mr." }
The easiest way for you to do this is to insert that field for the Word
Fields pulldown. If you enter it directly from the keyboard, use Ctrl+F9 to
insert each pair of field delimiters { }

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
> Ok, I cannot seem to figure this out or at least get it to work right.
> What I
[quoted text clipped - 11 lines]
>
> Sorry for the whining. I am just aggravated at it now.
mehherc - 03 Mar 2006 15:38 GMT
Ok, I must be showing my Blond, When I enter in IF { MERGEFIELD sex } = "F"
"Ms." Mr." , the text in word shows "MERGEFIELD". It might be working right,
but how do I tell WORD to go to that particular XLS sheet to match the "sex"
field?
mehherc - 03 Mar 2006 16:03 GMT
OK, never mind about how it gets the info from the excel sheet I figured that
out. But it still shows MERGEFIELD in the text, How do I change that so it
displays the Mr. or Ms.?
>Ok, I must be showing my Blond, When I enter in IF { MERGEFIELD sex } = "F"
>"Ms." Mr." , the text in word shows "MERGEFIELD". It might be working right,
>but how do I tell WORD to go to that particular XLS sheet to match the "sex"
>field?
Doug Robbins - Word MVP - 03 Mar 2006 16:53 GMT
I think that you must have omitted to read pr follow the last paragraph of
my post.

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
> OK, never mind about how it gets the info from the excel sheet I figured
> that
[quoted text clipped - 8 lines]
>>"sex"
>>field?
Charles Kenyon - 03 Mar 2006 17:52 GMT
Download the gender toolbar from my website. You can use the fields in it to
build the merge fields you need. http://addbalance.com/word/download.htm
Simply replace the { DocVariable Gender } fields with your test mergefields.
My fields test for "male" and "female".

Signature
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.
> Ok, I cannot seem to figure this out or at least get it to work right.
> What I
[quoted text clipped - 11 lines]
>
> Sorry for the whining. I am just aggravated at it now.