R
RizzKid
Maybe I'm going about this all wrong, but I just can't get date calculations
to work right. I'm using Word 2007. I have a document that gets updated once
a year and needs to display various date information based on a starting date
for the new year. So I set a custom document property ($Day1) as a date type
(3/1/2008). I need it to print out a week's worth of daily information in the
form "dddd, MMMM d, yyyy". So it should display
Saturday, March 1, 2008 ...
Sunday, March 2, 2008 ...
and so on for seven days.
I have read the Woody's Lounge article, but can't make his examples work for
me. I would have expected:
{SET QUOTE
{SET a{={DOCPROPERTY $Day1}}}
{SET b{=a+1}}
{b \@ "dddd, MMMM d, yyyy"}}
to give me the second date, but it merely gives me a "1".
Changing the final line to
{a \@ "dddd, MMMM d, yyyy"}}
for debug purposes gives me "Sunday, March 16, 2008", which is the current
date.
What am I missing? (Other than all that time I could have spent with my
family today)
to work right. I'm using Word 2007. I have a document that gets updated once
a year and needs to display various date information based on a starting date
for the new year. So I set a custom document property ($Day1) as a date type
(3/1/2008). I need it to print out a week's worth of daily information in the
form "dddd, MMMM d, yyyy". So it should display
Saturday, March 1, 2008 ...
Sunday, March 2, 2008 ...
and so on for seven days.
I have read the Woody's Lounge article, but can't make his examples work for
me. I would have expected:
{SET QUOTE
{SET a{={DOCPROPERTY $Day1}}}
{SET b{=a+1}}
{b \@ "dddd, MMMM d, yyyy"}}
to give me the second date, but it merely gives me a "1".
Changing the final line to
{a \@ "dddd, MMMM d, yyyy"}}
for debug purposes gives me "Sunday, March 16, 2008", which is the current
date.
What am I missing? (Other than all that time I could have spent with my
family today)