Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default How to do an if statement

Use

=M2&IF(N2"", ", "&N2,"")&IF(O2"",", "&O2,"")&IF(P2"",", "&P2,"")

--
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

"Serendipity" wrote in message
...
Thought this worked and then I noticed that if a Child field is blank, I
get
commas. How can I separate the names with commas in my statement but not
get
them in the result if that field is blank. This is the statement I used.

=CONCATENATE(M2,", ",N2,", ",O2,", ",P2)

Thanks!

"Doug Robbins - Word MVP" wrote:

The easiest thing for you to do would be to add another column to your
Excel
spreadsheet in which you concatenate the contents of the Child_One,
Child_Two, Child_Three and Child_Four fields for each record and then
just
use that one field in your mailmerge.

--
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

"Serendipity" wrote in message
...
Using Word 2003. Data in Excel 2003 spreadsheet. Performing mailmerge
in
Word. How do I make an if statement that will get the value from any
one
of
the fields below regardless of whether the other ones are empty or not?
I
have a directory which includes who the children in the family are--all
listed on one line--separated by commas--below the name and address
information. I have looked at the KB articles but their examples have
only
two fields, and I am not experienced enough to apply their examples to
a
more
complex senario.

These are the fields in Excel.

«Child_One» «Child_Two_» «Child_Three» «Child_Four»

Thanks for your help.






 
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
IF statement Paul J Microsoft Word Help 11 May 14th 07 06:04 PM
which statement right , question is Choose the correct statement? how many template?when we click new doc Microsoft Word Help 1 October 16th 06 11:15 AM
which statement right , question isChoose the correct statement? how many template?when we click new doc Microsoft Word Help 1 October 15th 06 11:20 PM
How can I? If statement ? Buttercup Mailmerge 2 November 23rd 05 06:49 PM
IF Statement Shoelaces Mailmerge 5 November 23rd 05 06:54 AM


All times are GMT +1. The time now is 01:07 AM.

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

About Us

"It's about Microsoft Word"