Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11
Default Number of Completed Months

Hi,

How can I get the number of COMPLETED months returned between 2 dates?

At times it may be grater than 12 months - but never greater than 24
months.

I've been fiddling with =Floor and =Ceiling but when the dates are in
a different year it has me stumped. For example ...

A1 = 15-Jun-07
A2 = 23-Oct-08

Need a formula to return "15" months

Tks, Kaye
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 10,593
Default Number of Completed Months

=DATEDIF(A1,A2,"M")

--
---
HTH

Bob


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



"Rick" wrote in message
...
Hi,

How can I get the number of COMPLETED months returned between 2 dates?

At times it may be grater than 12 months - but never greater than 24
months.

I've been fiddling with =Floor and =Ceiling but when the dates are in
a different year it has me stumped. For example ...

A1 = 15-Jun-07
A2 = 23-Oct-08

Need a formula to return "15" months

Tks, Kaye



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 76
Default Number of Completed Months

Hi

Try this - it can probably be simplified further:

=DATEDIF(A1,A2,"m")-(DAY(A1)<DAY(A2))+(DAY(A1)=1)+
(DATE(YEAR(A2),MONTH(A2)+1,0)=A2)

Richard


On Dec 27, 11:51 am, Rick wrote:
Hi,

How can I get the number of COMPLETED months returned between 2 dates?

At times it may be grater than 12 months - but never greater than 24
months.

I've been fiddling with =Floor and =Ceiling but when the dates are in
a different year it has me stumped. For example ...

A1 = 15-Jun-07
A2 = 23-Oct-08

Need a formula to return "15" months

Tks, Kaye


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11
Default Number of Completed Months

Thanks Bob and Richard for the rapid reply!

Cheers,
Kaye (via Rick's account)

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
Month name to number of months YTD Tasha Excel Worksheet Functions 7 July 26th 07 09:55 PM
Number of tasks completed in a specific time frame Robert Excel Discussion (Misc queries) 2 February 3rd 06 01:25 PM
how do I convert a number to number of years, months and days because Excel Worksheet Functions 2 October 12th 05 06:15 PM
Number of months between 2 dates john liem New Users to Excel 0 May 31st 05 06:08 PM
Want a number of cells to be auto completed based on entry in one. matt ashley Excel Worksheet Functions 1 April 14th 05 10:07 PM


All times are GMT +1. The time now is 03:20 AM.

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"