View Single Post
  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Graham Mayor
 
Posts: n/a
Default Showing today's date when the Excel value is zero

If today's date is being inserted into Word when there is a 0 in the data
file, then the merge is never seeing 0 as the result of the merge. You have
to check for what is *actually* being merged and not what you expect to be
merged.

What *exactly* does {Mergefield E_Start} produce?

You can then test for this instead of 0. If indeed it is today's date
(provided today's date is never E_start) then

{IF{MERGEFIELD E_Start} {Date}"{MERGEFIELD E_Start \@ "d MMMM yyyy"}"}

might be nearer the mark. You will probably have to add switches to both the
first E_Start and Date.

You may find it simpler to use an alternative means of connecting your merge
to the Excel data - see the Excel data section of
http://www.gmayor.com/mail_merge_lab...th_word_xp.htm

--

Graham Mayor - Word MVP

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



David Hall wrote:
Hi, this problem is really frustrating me so if you can help I would
really appreciate it.

I am using Word 2003 and Excel 2003 to do a mailmerge and I am having
a problem with today's date being inserted in the Word document when
the Excel value is zero. I would either like to show the date that is
entered in the Excel sheet or nothing if the Excel value is zero.

My entry in the Word document is:
{IF{MERGEFIELD E_Start} = 0 "" {MERGEFIELD E_Start \@ "d MMMM yyyy}

Where am I going wrong?

Many thanks
David Hall