View Single Post
  #8  
Old September 21st, 2009, 06:59 AM posted to microsoft.public.access.forms
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Calculate Chronological Age ex: 10yr 4mo 2days old

On Sun, 20 Sep 2009 22:03:02 -0700, Sync-opy
wrote:

Create a new Module on the modules tab. Copy and paste the code from the
website into the module; save it as "basDates" - actually any name *EXCEPT*
Diff2Dates.

To call it, create a Query based on your table. In a vacant Field cell of the
query type:

ChronoAge: Diff2Dates("ymd", [DOB], Date())

Base your form or report on this query.

Thank you for the assist. I am not sure how to use the code at the link. I
am new to the world of access. How do I get Date1 to pull information from
my [DOB] field for each record? How do I associate the code to the form
field to display age?

--

John W. Vinson [MVP]