I need to calculate the approximate current age in years of patients at a clinic.
We don't have the birthday of all the patients, but we know how old they were when then first registered and we know the date they registered.
I am doing a calculation which returns some strange numbers (e.g., 390, 1271, etc.), which obviously aren't correct.
My calculation goes:
CURRENT AGE = AGE AT REGISTRATION + (CURRENT DATE - DATE OF REGISTRATION).
How to I correct this to make it right?
Thanks.

FIXED IT. Divided the (CURRENT DATE - DATE OF REGISTRATION) by 365 and eureka!
Thanks.

In MS Access VBA you can use the DATEDIFF function

You might want to consider 365.25. Keep in mind that every four years there is an extra day :)

I think you could use the Year(date) calculation. Try setting up a new field as a calculation, with the following:
Year (registration date)- Age. That should get you somewhere near a birth year.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.