Excel - Calculation between time interval

December 2016



Issue


I want to retrieve sales within 24 months.

For example:

I have:
    • 22/09/2009 in cell A1 and 25/08/2011 in C1
    • 22/09/2009 in A2 and 25/10/2011 in C2

I wish to emphasize on the sales performed during the latest 24 months.

Solution


Use this formula:
=(YEAR(H4)-YEAR(D4))*12+MONTH(H4)-MONTH(D4) 

Related :

This document entitled « Excel - Calculation between time interval » from CCM (ccm.net) is made available under the Creative Commons license. You can copy, modify copies of this page, under the conditions stipulated by the license, as this note appears clearly.