Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Gordon Smith \(eMVP\)
 
Posts: n/a
Default Mail Merge from Excel - conditional field choice?

I'm working through my very first mail merge and have run into an issue
which I can't solve quickly by searching google and was hoping someone could
help. I'm an MVP but **not** a Word MVP. :-)

I would like to acheive the following in a single location in my mail merge
result (labels if you care). My data is in excel and among other data are
fields P1-P8 and J1-J8. I would like the merged result to be "the value of
P1 if it's not blank, otherwise the value of J1". I'll repeat for 2-8. I
saw that I can do "if the value of P1 is blank, use THIS text otherwise use
THAT text". I don't want conditional TEXT, I want conditional FIELD. Can
this be done?

Oh yeah - I would ideally like:
"and if using J1 use background color XX (not looked up - hard coded color
is fine)"

Thanks in advance

--
Gordon Smith (eMVP)


  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP
 
Posts: n/a
Default Mail Merge from Excel - conditional field choice?

You can use a mergefield in place of the conditional text,

{ IF { MERGEFIELD P1 } "" { MERGEFIELD P1 } { MERGEFIELD J1 } }

Use Ctrl+F9 for each pair of field delimiters { } and Alt+F9 to toggle off
their display.

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

"Gordon Smith (eMVP)" wrote in message
...
I'm working through my very first mail merge and have run into an issue
which I can't solve quickly by searching google and was hoping someone
could help. I'm an MVP but **not** a Word MVP. :-)

I would like to acheive the following in a single location in my mail
merge result (labels if you care). My data is in excel and among other
data are fields P1-P8 and J1-J8. I would like the merged result to be
"the value of P1 if it's not blank, otherwise the value of J1". I'll
repeat for 2-8. I saw that I can do "if the value of P1 is blank, use
THIS text otherwise use THAT text". I don't want conditional TEXT, I want
conditional FIELD. Can this be done?

Oh yeah - I would ideally like:
"and if using J1 use background color XX (not looked up - hard coded color
is fine)"

Thanks in advance

--
Gordon Smith (eMVP)




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
Word merge field names vs. Excel merge field names [email protected] Mailmerge 5 November 11th 05 05:24 PM
Mail Merge: Excel (XP) fields scrambled during merge Adprof Mailmerge 1 November 10th 05 06:43 PM
cannot mail merge from excel to word Alan Mailmerge 3 October 26th 05 05:03 AM
Insert Merge Field problem with Word-Mail Merge from Excel documen Augusta E. Microsoft Word Help 2 June 20th 05 10:59 AM
How do I get a field to self adjust in a mail merge? DD Holt Mailmerge 1 December 29th 04 06:30 PM


All times are GMT +1. The time now is 08:22 PM.

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

About Us

"It's about Microsoft Word"