Using If Then and Else with dates in a mail merge

M

macropod

Hi Chris,

To compare two dates you need to express them in ISO format (i.e. YYYYMMdd).
For example:
{IF{MERGEFILED Date1 \@ yyyyMMdd}>{CalculatedDate \@ yyyyMMdd} "True
Result" "False Result"}

To do math with dates in Word, you can't simply subtract a number from a
date in a mailmerge. To see how you can go about this, or do date
comparisons and much more with dates, download the Word document at:
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=249902
(url all one line)

Cheers
 
C

Chris ferb

I have set up a mail merge with an access database. The merge works fine, but
I am trying to display different messages if a date is from 90 days previous.

I have been using the following logic from my date field in the "If then
else" option:

[date] > (date-90)

I have data in the date field that should make the code trigger the the else
but it does not. Thanks for your help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top