AGE ( BirthDate )
Calculate the correct Age :)
Average rating: 4.3 (38 votes) Log in to vote
meddved - Show more from this author
meddved www.meddved.bg |
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
This function calculates the correct age.
Auto-correction for leap years.
Comments
comment, VR Apr 13, 2011 |
||
"This function calculates the correct age." No, it doesn't: a person born in 1900-03-15 is not yet 100 years old in 2000-03-14. Why not do the simple thing: Year ( today ) - Year ( DOB ) - ( today < Date ( Month ( DOB ) ; Day ( DOB ) ; Year ( today ) ) ) |
||
Daniel A. Shockley, New York, NY May 4, 2011 |
||
Try the following instead: http://www.briandunning.com/cf/518 It works, even on the birthday anniversaries and when dealing with leap years. It also gives you more detail and options, if desired. |
||
David Sep 21, 2016 |
||
thank you very much It has been very useful for my application. |
||
flusheDData, n/a Dec 6, 2020 |
||
Hi, Why not the simplest Int ( ( Get ( CurrentDate ) - BirthDate ) / 365,25 ) ? |
||
flusheDData, n/a Dec 6, 2020 |
||
I answer myself. Because sometimes it does not work. Eg.: for a BOD being 04/05/2008 and today being 04/05/2011 it gives 2 when it should be 3. So for me the most simple calculation would be VR's |
||
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.