I have an access database (MS Access 2002,) which stores school pupils information and I have very limited knowledge on VBA. Hopefully someone can help solve this one for me.
I have a form named frmPupils which contains the Date of Birth (field name - DOB).
I want to add a textbox to the form which will display a date that the pupil is
elegible to leave school, which is dependant on what is entered in the DOB field.
There are two possible school leaving dates in the year.
31st May and 31st December.
If a pupil's 16th birthday is on or between 1st March and 30th September
they can leave school on 31st May of that year.
If a pupil's 16th birthday is on or between 1st October until end of February,
28th or 29th if it's a leap year!
Then they can leave school on 31st December.
eg. If DOB = 16th August 1992, their 16th birthday is in August 2008,
(within the period between 1st March to 30th September),
so they can leave school on 31st May 2008.
If DOB = 16th February 1993, their 16th birthday will be in February 2009,
(within the period between 1st October to end of February),
so they can leave school on 31st December 2008.
Any help would be much appreciated.
I have a form named frmPupils which contains the Date of Birth (field name - DOB).
I want to add a textbox to the form which will display a date that the pupil is
elegible to leave school, which is dependant on what is entered in the DOB field.
There are two possible school leaving dates in the year.
31st May and 31st December.
If a pupil's 16th birthday is on or between 1st March and 30th September
they can leave school on 31st May of that year.
If a pupil's 16th birthday is on or between 1st October until end of February,
28th or 29th if it's a leap year!
Then they can leave school on 31st December.
eg. If DOB = 16th August 1992, their 16th birthday is in August 2008,
(within the period between 1st March to 30th September),
so they can leave school on 31st May 2008.
If DOB = 16th February 1993, their 16th birthday will be in February 2009,
(within the period between 1st October to end of February),
so they can leave school on 31st December 2008.
Any help would be much appreciated.
Comment