ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   subtract years and months (as in ages) from another age (https://www.excelbanter.com/excel-discussion-misc-queries/129141-subtract-years-months-ages-another-age.html)

Rumplestiltskin

subtract years and months (as in ages) from another age
 
How do I use excel to subtract one age from another, for example 11 years 5
months from 14 years 3 months?

Bob Phillips

subtract years and months (as in ages) from another age
 
Subtract the original cells from each other and convert in the same way that
you did for these two.

--
HTH

Bob Phillips

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Rumplestiltskin" wrote in
message ...
How do I use excel to subtract one age from another, for example 11 years

5
months from 14 years 3 months?




Newbeetle

subtract years and months (as in ages) from another age
 
Hi on the cells you wish to enter the dates, select them, then right mouse
click and select Format cells.

Select custom from the list and type in yy"Years" mm"months"

If you want to see 11 Years 5 months in the cell you have applied the custom
format type 1/5/11
If you want to see 14 Years 3 Months, type in the other cell 1/3/14

In the cell you want the answer, apply the custom format the same as above,
then simply do =cell-other cell, ie so if you have date of 14Y 3M in cell A1
and 11y 5m in B1 in cell C1 type = a1-b1

Hope that helps


--
This post was created using recycled electrons!


"Rumplestiltskin" wrote:

How do I use excel to subtract one age from another, for example 11 years 5
months from 14 years 3 months?


Newbeetle

subtract years and months (as in ages) from another age
 
Hi this is another way and should be more accurate as the other way I said
can be out by a month on certain dates.

A B C
D E
Cell1] Years Months Total Months
Cell2] 14 3 =(A2*12)+B2
Cell3] 11 5 =(A3*12)+B3
Cell4] =ROUNDDOWN(D4,0) =C4-(A4*12) =C2-C3 =C4/12

You can then format to look exactly as you want
--
This post was created using recycled electrons!


"Newbeetle" wrote:

Hi on the cells you wish to enter the dates, select them, then right mouse
click and select Format cells.

Select custom from the list and type in yy"Years" mm"months"

If you want to see 11 Years 5 months in the cell you have applied the custom
format type 1/5/11
If you want to see 14 Years 3 Months, type in the other cell 1/3/14

In the cell you want the answer, apply the custom format the same as above,
then simply do =cell-other cell, ie so if you have date of 14Y 3M in cell A1
and 11y 5m in B1 in cell C1 type = a1-b1

Hope that helps


--
This post was created using recycled electrons!


"Rumplestiltskin" wrote:

How do I use excel to subtract one age from another, for example 11 years 5
months from 14 years 3 months?



All times are GMT +1. The time now is 02:51 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com