KeithGorham
MIS
Can anyone tell me what formula to use to calculate a person's age. I have a field for the date of birth and need a field that will calculate and update their age on their birth day.
Thanks
Thanks
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Public Function basDob2AgeShort(DOB As Date) As Integer
'? basDob2AgeShort(Date)
'Or how to use simple functions to generate _
erronous results
Dim Idx As Integer
Dim MyDt As Date
MyDt = DOB - 15
' While Idx <= 30
'
' Debug.Print DOB, MyDt, Format((Date - MyDt), "yy")
' Idx = Idx + 1
' MyDt = MyDt + 1
'
' Wend
basDob2AgeShort = Format((Date - DOB), "yy")
End Function
DateDiff("yyyy",[dthire],Now())+Int(Format(Now(),"mmdd")<Format([dthire],"mmdd"))