Skip to main content
Question

Age today

  • July 31, 2020
  • 0 replies
  • 34 views

I for the life of me can't figure out the formula to calculate today's age based on a simple date field called DOB. Help!

------------------------------
Mike McCartney
------------------------------
This topic has been closed for replies.

Forum|alt.badge.img+15
  • Registered
  • August 1, 2020
Mike,

The simplest answer is a  Formula Duration field

Today()-[DOB]

However, you need very young people because it will display their age in Days when you have smart units set.

What are you using the information for?  Do you need it in another calculation?  If so then this is fine.

If you are going to show it to a User to make a decision on then change to a Formula Rich Text
This will show whole years.

var number Age =ToDays(Today()-[DOB]);
var number AgeYears = Round(($Age)/365);
ToText($AgeYears)

------------------------------
Don Larson
Paasporter
Westlake OH
------------------------------

  • Author
  • Registered
  • August 1, 2020
Thanks. Worked well.

------------------------------
Mike McCartney
------------------------------