Finding years between dates

Dan Wilson

Well-known Member
Joined
Feb 5, 2006
Messages
507
Office Version
  1. 365
Platform
  1. Windows
Good day. I am running Excel out of Office 365 (updated) on Windows 10 Home. I am creating a worksheet to track birthdays. I would like to be able to enter a person's birthdate and then show their age in a separate cell. I have achieved this by formatting the birthdate as a Date, then using a cell to extract the year from that and formatting the cell to Number with no decimal points. Then I extract the year from Today() using another cell with the same Number format. Finally, another cell extracts the difference between the two extracted cells to get the person's age. There must be an easier way to do this. Any help is appreciated.
Thank you,
Dan Wilson...
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
How about
Excel Formula:
=DATEDIF(A2,TODAY(),"Y")
 
Upvote 0
Solution
How about
Excel Formula:
=DATEDIF(A2,TODAY(),"Y")
Good day Fluff. You did it again! Apparently DATEDIF is a new or hidden function as it does not show up in my choice of functions. Had it been there, I would have tried it. Thank you, and this one is closed.
Dan Wilson...
 
Upvote 0
Hi,

DATEDIF is a old function dating back to Lotus123

If you want to try a function what would show up in Excel, you can use YEARFRAC:

Excel Formula:
=INT(YEARFRAC(A2,TODAY(),1))
 
Upvote 0
Glad to help & thanks for the feedback.
 
Upvote 0
Hi,

DATEDIF is a old function dating back to Lotus123

If you want to try a function what would show up in Excel, you can use YEARFRAC:

Excel Formula:
=INT(YEARFRAC(A2,TODAY(),1))
Good day jtakw. Thank you for responding. I tried the YEARFRAC, but could not get it to work. The DATEDIF did work.
 
Upvote 0
Glad to help & thanks for the feedback.
Hi Fluff. I was going to ask you to tell me where to find a complete list of Excel Functions, but then I looked in Help and there it was. Thanks again.
Dan Wilson...
 
Upvote 0

Forum statistics

Threads
1,214,593
Messages
6,120,435
Members
448,962
Latest member
Fenes

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top