Date Of Birth

charliebcc

New member
Local time
Today, 23:20
Joined
Dec 14, 2001
Messages
8
I am using a data entry form where I have a Date of Birth field. How can I have the age appear in another box after the DOB is entered?
 
Age = DateDiff("yyyy", [Bdate], Now())+ Int( Format(now(), "mmdd") < Format( [Bdate], "mmdd") )

Change the Bdate field to the name of your DOB field and put this in the After Update event of the DOB field. Set Age to the correct name of your age field.

[This message has been edited by Jack Cowley (edited 12-14-2001).]
 
Thanks very much for the quick response. This works fine until I enter a date that is lower then 1930. This will be used in an ambulance squad for patients and there will be patients under that date. When I enter any date below 1930 I get a -number. ie: 3/11/29 gives me -28 while 3/11/30 returns the correct age 71. Please help.
 

Users who are viewing this thread

Back
Top Bottom