Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Bill Helbron
 
Posts: n/a
Default Formula for Date Calculation

I have a spreadsheet that includes a "Birth" and "Death" column and an "Age"
column. Calculating the age is simple but what I want to do is, if the person is
still living, would like to calculate their age as of the current date and
perhaps using a different color. Any suggestions for a formula?

Bill
  #2   Report Post  
Posted to microsoft.public.excel.misc
daddylonglegs
 
Posts: n/a
Default Formula for Date Calculation


If you just want the age in years

=DATEDIF(A1,TODAY(),"Y")

where A1 contains the date of birth


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=539433

  #3   Report Post  
Posted to microsoft.public.excel.misc
saziz
 
Posts: n/a
Default Formula for Date Calculation


Try this:

a1 DOB
b1 =now()
c1 =DATE(YEAR(TODAY())+(DATE(YEAR(TODAY()),MONTH(E1),
DAY(A1))<TODAY()),MONTH(A1),DAY(A1))
d1 =TEXT(G1,"dddd")

b5 = DATEDIF(A1,NOW(),"ym") & " Months"
c5 =DATEDIF(A1,NOW(),"md") & " Days"
a5 =DATEDIF(A1,NOW(),"y") & " Years


You will get age calculated in row 5 ABC
Syed


--
saziz
------------------------------------------------------------------------
saziz's Profile: http://www.excelforum.com/member.php...fo&userid=6350
View this thread: http://www.excelforum.com/showthread...hreadid=539433

  #4   Report Post  
Posted to microsoft.public.excel.misc
Bill Helbron
 
Posts: n/a
Default Formula for Date Calculation

Thanks daddylonglegs & Syed,

I tried both of your solutions and ended up with the same result - both
incorrect! As an example, I have "1935" in cell C3. When I type each of your
formulas into E3, I get "101". It should be "71"! What am I doing wrong?

Bill

On Fri, 5 May 2006 17:40:28 -0500, saziz
wrote:


Try this:

a1 DOB
b1 =now()
c1 =DATE(YEAR(TODAY())+(DATE(YEAR(TODAY()),MONTH(E1),
DAY(A1))<TODAY()),MONTH(A1),DAY(A1))
d1 =TEXT(G1,"dddd")

b5 = DATEDIF(A1,NOW(),"ym") & " Months"
c5 =DATEDIF(A1,NOW(),"md") & " Days"
a5 =DATEDIF(A1,NOW(),"y") & " Years


You will get age calculated in row 5 ABC
Syed

  #5   Report Post  
Posted to microsoft.public.excel.misc
Pete_UK
 
Posts: n/a
Default Formula for Date Calculation

If C3 is meant to be date of birth, then you should enter it as
6/6/1935 (or whatever), not just the year.

Hope this helps.

Pete



  #6   Report Post  
Posted to microsoft.public.excel.misc
Bill Helbron
 
Posts: n/a
Default Formula for Date Calculation

Hi Pete,

Problem is I don't have the complete birth date, just the year!

Bill

On 5 May 2006 17:58:26 -0700, "Pete_UK" wrote:

If C3 is meant to be date of birth, then you should enter it as
6/6/1935 (or whatever), not just the year.

Hope this helps.

Pete

  #7   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Formula for Date Calculation

You can subtract just the year:

=year(today())-a1
(format the cell as General)

But depending on today's date and the actual birthdate, you could be off by one.

If someone were born in 2005, are they 0 or 1 year old?

Depends on if their birthday has passed.



Bill Helbron wrote:

Hi Pete,

Problem is I don't have the complete birth date, just the year!

Bill

On 5 May 2006 17:58:26 -0700, "Pete_UK" wrote:

If C3 is meant to be date of birth, then you should enter it as
6/6/1935 (or whatever), not just the year.

Hope this helps.

Pete


--

Dave Peterson
  #8   Report Post  
Posted to microsoft.public.excel.misc
Bill Helbron
 
Posts: n/a
Default Formula for Date Calculation

Hi Dave,

Thanks! That is exactly what I wanted.

Bill

On Sat, 06 May 2006 07:12:55 -0500, Dave Peterson
wrote:

You can subtract just the year:

=year(today())-a1
(format the cell as General)

But depending on today's date and the actual birthdate, you could be off by one.

If someone were born in 2005, are they 0 or 1 year old?

Depends on if their birthday has passed.



Bill Helbron wrote:

Hi Pete,

Problem is I don't have the complete birth date, just the year!

Bill

On 5 May 2006 17:58:26 -0700, "Pete_UK" wrote:

If C3 is meant to be date of birth, then you should enter it as
6/6/1935 (or whatever), not just the year.

Hope this helps.

Pete

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Speed up calculation of a worksheet that contains formula vennila Excel Worksheet Functions 2 April 24th 06 01:42 PM
Price function difference in Output formula vis a vis Manual Calculation abhi_23 Excel Worksheet Functions 0 January 17th 06 07:57 AM
Formula Problem - interrupted by #VALUE! in other cells!? Ted Excel Worksheet Functions 17 November 25th 05 05:18 PM
Time Calculation Formula! Mike Excel Discussion (Misc queries) 5 July 23rd 05 04:37 AM
Initial Formula Calculation jestersdead Excel Discussion (Misc queries) 3 July 4th 05 02:07 AM


All times are GMT +1. The time now is 11:44 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"