Date Formula - AM I EXPIRED!

trackmedic

Registered User.
Local time
Today, 23:13
Joined
Aug 20, 2001
Messages
115
I have been trying to figure out a formula to determine if an item is expired.

i would like to compare the "maindate" to an "expiration date"

i would like this to show up 60 days before the expiration date expires. for example if the expiration is 11-30-2010 i I would like a warning to appear on 08-30-2010 stating that the item is about to expire.

thanks in advance.
 
You can use "datediff" and "now()". Both are in Access help. Will require some tweaking.
Me.Text18 = DateDiff("d", Now(), Me.deadlinedate)
Text18 = the number of days left before the deadline is reached, or days left before your product expires. You can use VBA to make "Text18" visible/invisible when its value achieves a certain threshold.
 
Last edited:
Hi,

Not sure about VBA, but if it was me I would have this displayed on a form, or even in a query. See attached jpg for the formula. I have used things just like this many times before.

Not sure about the American date format but I think the example you gave is 90 days not 60. I've used 90 days in my formula.

Pat.
 

Attachments

  • Expiration warning.JPG
    Expiration warning.JPG
    25.8 KB · Views: 244

Users who are viewing this thread

Back
Top Bottom