Lesson#20: Making an age calculator in excel with DATEDIF function

Lesson#20: Making an age calculator in excel with DATEDIF function
In this post, we will talk about the formula DATEDIF(). This
the formula is used to get the difference in days, months, or years between two
dates.
In excel we are unable to find any help with the formula
but it works if we configure it properly.
Syntax of the formula is =DATEDIF (start_date, end_date, unit)
start_date –
The start date is the earlier date in serial number format.
end_date – End
date is the late date serial number format.
unit – The time
unit to use (years, months, or days).
I have mentioned how the units are configured.
Unit
Return value
“Y”
The difference in complete years
“M”
The difference in complete months
“D”
Difference in days
“MD”
Remaining days, after complete months
“YM”
Remaining months, after complete years
“YD”
Remaining  days, after complete
years

Now I will show how to use this function by making an age calculator.

I have made a spreadsheet as I have shown in the picture which will take input from the user and convert it into a date using this formula =DATE(E6, E5, E4)




Now I will add this formula in the below cell to show the age which will calculate the difference between the input data and TODAY() (present date). the formula will be =CONCATENATE(DATEDIF(D7, TODAY(), “y”), ” Years “, DATEDIF(D7, TODAY(), “ym”), ” Months “, DATEDIF(D7, TODAY(), “md”), ” Days”) 


Here I have provided a download link for this file.
excelabcd-agecalculator

Related video tutorials:

See also  Lesson#25: Function WEEKNUM has a good use for construction people

Hi! I am Puspendu. I am the founder and author of Excelabcd. I am little creative person, blogger and Excel-maniac guy. I hope you enjoy my blog.

Leave a Reply

Your email address will not be published. Required fields are marked *

*