Frasier13 Posted May 3, 2006 Posted May 3, 2006 Hi there I found the following calculation on a post on here and I have been trying to modify it so that I can calculate someones age based on the current date. This way their age will update each year in relation to the current date. However, out of 10 I would say i'm at level 2 or 3 so I don't fully understand it and it doesn't work when I modify it. Year(Date( 8; 1; Year(Get(CurrentDate)) + (GetAsNumber(Get(CurrentDate)) > GetAsNumber(Date( 8; 1; Year(Get(CurrentDate))) )) )) - Year(birthdate) - (GetAsNumber(Date( 8; 1; Year(Get(CurrentDate)) + (GetAsNumber(Get(CurrentDate)) > GetAsNumber(Date( 8; 1; Year(Get(CurrentDate))))) )) < GetAsNumber(Date(Month(birthdate); Day(birthdate); Year(Date( 8; 1; Year(Get(CurrentDate)) + (GetAsNumber(Get(CurrentDate)) > GetAsNumber(Date( 8; 1; Year(Get(CurrentDate))) ))) )))) I also tried a simple calculation: Todays date - birthdate But the result isn't quite working out. I have trawled through other posting but I can't seem to find anything that will help me. Thanks in advance.
John Mark Osborne Posted May 3, 2006 Posted May 3, 2006 GetAsNumber(Year(Get(CurrentDate)) - Year(DOB) - Case(Get(CurrentDate) < Date(Month(DOB); Day(DOB); Year(Get(CurrentDate))); 1; 0))
Frasier13 Posted May 3, 2006 Author Posted May 3, 2006 You're a star!!! If you lived locally i'd buy you a pint the next time you're out in Manchester!!! Much appreciated.
John Mark Osborne Posted May 3, 2006 Posted May 3, 2006 I just got back from the UK a few months ago and am visiting again probably at the end of the summer. So, I may have to take you up on the offer.
Recommended Posts
This topic is 6841 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now