Age Help

Michael Cadle

New Member
Joined
May 13, 2007
Messages
18
Everone one is so very helpful here.

I have another issue I need help with.

cell A1 contains their birthday. I want cell A2 to contain their age as of today.

If A1 is blank then I want A2 to remain blank. Thus there is no age calucation until a birthday is entered into A1.

The age can be simple just the year.

Again thanks everyone for your help. This is a great place.
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.

mhenk

Well-known Member
Joined
Jun 13, 2005
Messages
591
Probably way too complicated, but this is the first one of mine that I came across:
Code:
=YEAR($D$8)-YEAR($D$18)-IF(MONTH($D$8)<MONTH($D$18),1,0)-IF(AND(MONTH($D$8)=MONTH($D$18),DAY($D$8)<DAY($D$18)),1,0)
D8 is the birthday, D18 is the evaluation day, can be changed to now(), probably.

Strap an if statement on there and you're good to go
 
Upvote 0

facethegod

Well-known Member
Joined
Aug 1, 2006
Messages
767
Try this.... age is based on 30 day months w/ a 360 day year



Code:
=IF(A1="","",(YEAR(TODAY())-YEAR(A1))+IF(DAY(TODAY())<DAY(A1),MONTH(TODAY())-1-MONTH(A1),MONTH(TODAY())-MONTH(A1))/12+IF(DAY(TODAY())<DAY(A1),30+DAY(TODAY())-DAY(A1),DAY(TODAY())-DAY(A1))/360)
 
Upvote 0

Michael Cadle

New Member
Joined
May 13, 2007
Messages
18
The age calucation is the easy part

=DATEDIF(L14,NOW(),"y")

What I dont know how to acomplish is if cell L14 is empty I do not want a date in cell M14.

Anyt thoughts
 
Upvote 0

Joe Was

MrExcel MVP
Joined
Feb 19, 2002
Messages
7,539
=If(L14="","",DATEDIF(L14,NOW(),"y"))
 
Upvote 0

Traveler

Board Regular
Joined
May 14, 2007
Messages
149
The age can be simple just the year.
Code:
=IF(A1="","",YEAR(TODAY())-YEAR(A1))
make sure you format the cell as General. Excel tries to be helpful and changes the format to Date when it sees such things as dates in the formula.
 
Upvote 0

brian.wethington

Well-known Member
Joined
Jul 20, 2006
Messages
1,739
The age can be simple just the year.
Code:
=IF(A1="","",YEAR(TODAY())-YEAR(A1))
make sure you format the cell as General. Excel tries to be helpful and changes the format to Date when it sees such things as dates in the formula.
what about if they have not had their birthday yet this year?

As for your other part, the datedif functions work fine to get the age... this will get your if portion taken care of

=if(A1, FunctionHere, "")
 
Upvote 0

Forum statistics

Threads
1,190,876
Messages
5,983,355
Members
439,840
Latest member
billy1989

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
Top