ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Calculating the number of months (https://www.excelbanter.com/excel-discussion-misc-queries/264054-calculating-number-months.html)

Philangr8

Calculating the number of months
 
I have a column for start date and end date. I would like a formular that
tells me how many months it is including the start month and end month.

ex. Start date: 11/1/2009 end date: 4/1/2010 this would be 6 months if you
include November and April.

Thanks in advance

FSt1

Calculating the number of months
 
hi
assuming that start date is in A1 and end date is in b1....
=DATEDIF(A1,B1,"m")+1

regards
FSt1

"Philangr8" wrote:

I have a column for start date and end date. I would like a formular that
tells me how many months it is including the start month and end month.

ex. Start date: 11/1/2009 end date: 4/1/2010 this would be 6 months if you
include November and April.

Thanks in advance


FSt1

Calculating the number of months
 
forgot to add
format as general

regards
FSt1

"Philangr8" wrote:

I have a column for start date and end date. I would like a formular that
tells me how many months it is including the start month and end month.

ex. Start date: 11/1/2009 end date: 4/1/2010 this would be 6 months if you
include November and April.

Thanks in advance


David Biddulph[_2_]

Calculating the number of months
 
Wouldn't that return 1 month if the dates were 20 May and 10 Jun? Doesn't
the OP want to include both months?

Mightn't he want
=DATEDIF(DATE(YEAR(A1),MONTH(A1),1),DATE(YEAR(B1), MONTH(B1),1),"m")+1 ?
--
David Biddulph


"FSt1" wrote in message
...
forgot to add
format as general

regards
FSt1

"Philangr8" wrote:

I have a column for start date and end date. I would like a formular that
tells me how many months it is including the start month and end month.

ex. Start date: 11/1/2009 end date: 4/1/2010 this would be 6 months if
you
include November and April.

Thanks in advance





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

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