Dear Macropod,
Help.... my date calculation does not automatically update based on the
current date. This is the calculation I have in my document and it works
great the day I added to the document, but it does not update. The
document
I am adding this calculation to is a template that is used daily by my
users,
what do I need to add to the calculation to make it automatically update
whenever the document is generated.
For example, User #1 generates the document (using my template) on
November
26th, I need the date of January 25, 2008 to be entered wherever I have
the
date calculation logic. Then User #2 generates the same document (using
my
template) on November 27, 2007. I need the date of January 26, 2008 to be
entered wherever I have the date calculation logic.
This is the date calculation logic I am using.
{QUOTE{{DATE /@ "MMMM d, yyyy" \* MERGEFORMAT}}{set Delay "60"}{SET
d{StartDate \@ d}}{SET m{ StartDate \@ MM}}{StartDate \@ yyyy }}{SET
jd{=INT(365.25*(y+4799+INT((m+10)/12)))+INT(367/12*MOD(m+10,12))-INT(3*INT((y+4901+INT((m+10)/12))/100)/4)+d-32075}}{SET
jd{=jd+Delay }}{SET c
{=jd+68569-INT(36524.25*INT((jd+68569)/36524.25)+0.75)}}{ SET
f{=c-INT(365.25*INT((c+1)/365.25025))+31}}{SET
dd{=f-INT(30.58757*INT(f/30.58757))}}{SET
mm"{=INT(f/30.58757)+2-12*INT(INT(f/30.58757)/11)} /00"}{SET
yy{=100*(INT((jd+68569)/36524.25)-49)+INT((c+1)/365.25025)+INT(INT(f/30.58757)/11)}}{mm
\@ MMMM } 160{dd}, 160{yy}""}
Your help is GREATLY appreicated.
--
Rcoppi
macropod said:
To see how to do this and just about everything else you might want to do
with dates in Word, check out my Date Calc 'tutorial', at:
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=249902
or
http://www.gmayor.com/downloads.htm#Third_party
In particular, look at the item titled 'Date and Time Calculations In A
Mailmerge'
Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------
Rcoppi said:
Hi,
I have several documents in which I enter a date in one location that
must
be increased by 60 days in several other locations in the same
document.
I've used ASK statements to automatically enter information that is
entered
in response to my question in multiple locations in a document, but I'm
not
sure how to do this, or if I even can do this. Help!!!!