Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to calculate remain days using dates?

Status
Not open for further replies.

jimrawr

MIS
Oct 8, 2005
16
US
I am trying to do this in a form. I have an Epiration date, and I need to calculate remaining days...

I.E Epiration date = 12/25/05
Todays Date = 10/10/05

Remaining = 12/25/05 - 10/10/05

Can someone tell me the code that needs to go into the control source? Thanks!!
 
=datediff ("d", Date(), ExpiryDate)

- Replace ExpiryDate with the name of your field.

John
 
How are ya jimrawr . . .

For working days between two dates, have a look here:

How to Find Number of Working Days Between Two Dates

Calvin.gif
See Ya! . . . . . .
 
Thanks for the help guys...

I havent had a chance yet to check the code, but does that code jrbarnett gave calculate using the system date? Thats what I need... Expiration date - system date = days left

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top