For instance, let's say I have a date of 10/23/11. I want to convert this date to decimals. So 10/23/11 would be 9.7419 months in this calender year. How does one do this?
For instance, let's say I have a date of 10/23/11. I want to convert this date to decimals. So 10/23/11 would be 9.7419 months in this calender year. How does one do this?
Office 2010
Assume your current date is in M3 and your start of the year date is in M2, then use this formula.
=MONTH(M3)-MONTH(M2)+(M3-DATE(YEAR(M3),MONTH(M3),1))/(EOMONTH(M3,0)-EOMONTH(M3,-1))
Format as a number with as many decimals you want.
Alan
Alan עַם יִשְׂרָאֵל חַי
Change an Ugly Report with Power Query
Database Normalization
Complete Guide to Power Query
Man's Mind Stretched to New Dimensions Never Returns to Its Original Form
With a date in A1 this formula should do it
=MONTH(A1)-1+DAY(A1)/DAY(EOMONTH(A1,0))
format as number
Audere est facere
Awesome! I had almost the same formula using days, I was not aware I could do months as well. Very big thanks to both of you!
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks