If possible, do this in your data source - e.g. if it's an Access/SQL Server
database, make a query/view that calculates date+5 or date+89, use that as
the data source and insert that field just like any other. That won't work
unless you know the number of days you need to add at the point when the
query is executed (which you may not know if, for example, the user types
the value into an ASK field).
Otherwise, download the macropod's attachment at :
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=249902
You may also find http://tips.pjmsn.me.uk/t0004.htm useful.
Peter Jamieson
>I have been requested to create a merge document. One of the fields that
>is
> being requested is to calculate a date in the future (5 days from today,
> 89
> days from, etc.). Can you create a field in a merge document that would
> calculate something like that? If so, how would one do it?
I wish I could do that, but the data source, an Excel spreadsheet, will be
controlled by someone else. Thanks for the links. I'll take a look at them
to see if they contain what I need. In the meantime, do you know how I would
set up the merge field to calculate this info?
Thanks again.
> If possible, do this in your data source - e.g. if it's an Access/SQL Server
> database, make a query/view that calculates date+5 or date+89, use that as
[quoted text clipped - 16 lines]
> > days from, etc.). Can you create a field in a merge document that would
> > calculate something like that? If so, how would one do it?
Peter Jamieson - 13 Jun 2007 07:59 GMT
> In the meantime, do you know how I would
> set up the merge field to calculate this info?
The trouble is that the calculation using fields is not at all simple, which
is why you need the stuff in here: (it shows you how to do the calculations
using fields):
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=249902
<<
>I wish I could do that, but the data source, an Excel spreadsheet, will be
> controlled by someone else.
You may still be able to do the calculation "in the data source" using Word
VBA to issue the necessary Jet SQL. It's described in the other article.
Peter Jamieson
>I wish I could do that, but the data source, an Excel spreadsheet, will be
> controlled by someone else. Thanks for the links. I'll take a look at
[quoted text clipped - 31 lines]
>> > would
>> > calculate something like that? If so, how would one do it?