Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Worksheet Functions / February 2008

Tip: Looking for answers? Try searching our database.

Calculating Months while taking into consideration days

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Excel Trouble - 08 Feb 2008 17:45 GMT
If I use the suggested formula
"=(YEAR(A4)-YEAR(A3))*12+MONTH(A4)-MONTH(A3)"  
It will indeed calculate the number of months inbetween two dates, however.

If the date is in question is 2/9/05 and todays current date is 2/8/08
the answer will display as 36 months.  That in fact, is incorrect.  I want
it to take days into consideration.  The correct answer should be 35 months,
and on the 9th of 2008 it will infact be 36 months.  How do I make the proper
adjustments???
Ron Rosenfeld - 08 Feb 2008 17:50 GMT
>If I use the suggested formula
>"=(YEAR(A4)-YEAR(A3))*12+MONTH(A4)-MONTH(A3)"  
[quoted text clipped - 5 lines]
>and on the 9th of 2008 it will infact be 36 months.  How do I make the proper
>adjustments???

Try

=DATEDIF(A1,A2,"m")

--ron
Niek Otten - 08 Feb 2008 17:52 GMT
Look here:

http://www.cpearson.com/excel/datedif.aspx

Signature

Kind regards,

Niek Otten
Microsoft MVP - Excel

| If I use the suggested formula
| "=(YEAR(A4)-YEAR(A3))*12+MONTH(A4)-MONTH(A3)"
[quoted text clipped - 5 lines]
| and on the 9th of 2008 it will infact be 36 months.  How do I make the proper
| adjustments???
Gary''s Student - 08 Feb 2008 17:57 GMT
With A1 and A2 having:

2/9/2005
2/8/2008

=DATEDIF(A1,A2,"m")
returns 35
Signature

Gary''s Student - gsnu200768

> If I use the suggested formula
> "=(YEAR(A4)-YEAR(A3))*12+MONTH(A4)-MONTH(A3)"  
[quoted text clipped - 5 lines]
> and on the 9th of 2008 it will infact be 36 months.  How do I make the proper
> adjustments???
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.