R
ricky
Good morning everyone,
Just a quick question, which I am sure is quite trivial, but I am not sure
how to handle Leap Years.
I have an Access form, which contains details about motor policies.
I also have a command button - "Renew", which when clicked, increments the
"Start Date" by one year and the "End Date" by one year, minus one day.
For example, this is what I get:
Before Renewal:
Start Date = 01/MAR/2006
End Date = 28/FEB/2007
After Renewal:
Start Date = 01/MAR/2007
End Date = 27/FEB/2007
***************************************************
However next year is a leap year, so I need to show the following:
After Renewal:
Start Date = 01/MAR/2007
End Date = 29/FEB/2007
Any ideas?
Kind regards
Ricky
Just a quick question, which I am sure is quite trivial, but I am not sure
how to handle Leap Years.
I have an Access form, which contains details about motor policies.
I also have a command button - "Renew", which when clicked, increments the
"Start Date" by one year and the "End Date" by one year, minus one day.
For example, this is what I get:
Before Renewal:
Start Date = 01/MAR/2006
End Date = 28/FEB/2007
After Renewal:
Start Date = 01/MAR/2007
End Date = 27/FEB/2007
***************************************************
However next year is a leap year, so I need to show the following:
After Renewal:
Start Date = 01/MAR/2007
End Date = 29/FEB/2007
Any ideas?
Kind regards
Ricky