I've got a util written by Rick Borup http://www.prairienet.org/ita , that
was posted on VFUG that returns the number of Years, Months, & Days.
Will send to any off list that asks

Rick Quilhot
Gallant Transport, Inc
877-Gallant
mailto:[EMAIL PROTECTED]
<*))))))><{

 -----Original Message-----
From:   [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]  On Behalf
Of Hal Kaplan
Sent:   Monday, November 27, 2006 12:33 PM
To:     ProFox Email List
Subject:        RE: dob to age

Why are you concerned about being a day off when all Brian's code does is
subtract the birth year from the current year.  Brian's code is wrong for
every date prior to the birthdate.  That is if your birthday is Nov 30,
2000, Brian's code says you are 6 when you are really 5 for the whole year
up to Nov 30th.

If you are going to use Brian's "algorithm," this is much simpler ....

age=year(date())-year(birthdate)


Of course, you are in the best position to judge how accurate (or
inaccurate) your calculations need to be <g>

HALinNY

=> -----Original Message-----
=> [mailto:[EMAIL PROTECTED] On Behalf Of Andy Davies
=> Tom Slayton said "INT((tdDate-tdBirthDate)/365.25)"
=>
=> thanks Tom, I was thinking along those lines myself but
=> wasn't sure that it wouldn't occasionally be a day out - I'm
=> going to go with Brian Abbots suggestion.
=> ( Brian Abbot said:
=> INT((VAL(DTOS(dToday))-VAL(DTOS(dBirth)))/10000) )
=>
=> Andrew Davies  MBCS CITP


[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to