Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / March 2008

Tip: Looking for answers? Try searching our database.

Date Math

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Paul Mayer - 14 Mar 2008 17:51 GMT
If I have two date fields MyStartDate and MyStopDate that can be set by the
date picker is it possible once MyStartDate is selected to set MyStopDate to
MyStartDate+7 days?
Clay Fox - 14 Mar 2008 18:14 GMT
In InfoPath 2007 they have a new function adddays() that will do what you
want to set the default.

Otherwise you have to use a script function like Datediff in VBScript. Also
if you want to calculate the difference between dates or any other thing like
that.

There are examples of the code at http://www.infopathdev.com search on
datediff
Signature

Clay Fox / Microsoft InfoPath MVP
www.InfoPathDev.com / The InfoPath Authority / Downloads, Samples, How-To,
Experts, Forum

> If I have two date fields MyStartDate and MyStopDate that can be set by the
> date picker is it possible once MyStartDate is selected to set MyStopDate to
> MyStartDate+7 days?
Paul Mayer - 14 Mar 2008 18:49 GMT
Clay:

I should have specified I am using IinfoPath 2003.  I just want to be able
to select the start date for a report and have the end date be set to the
StartDate+7 day.

Paul

> In InfoPath 2007 they have a new function adddays() that will do what you
> want to set the default.
[quoted text clipped - 9 lines]
> > date picker is it possible once MyStartDate is selected to set MyStopDate to
> > MyStartDate+7 days?
Clay Fox - 14 Mar 2008 19:05 GMT
Then your only option is the Datediff function.
Signature

Clay Fox / Microsoft InfoPath MVP
www.InfoPathDev.com / The InfoPath Authority / Downloads, Samples, How-To,
Experts, Forum

> Clay:
>
[quoted text clipped - 17 lines]
> > > date picker is it possible once MyStartDate is selected to set MyStopDate to
> > > MyStartDate+7 days?

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.