Monday, May 21, 2012

Calculating between dates

Calculating with dates is always tricky. Here's a neat formula that spells it out !

Where
A1 = 01/01/2012
A2 = 21/05/2012

=DATEDIF(A1,A2,"y")&" years "&DATEDIF(A1,A2,"ym")&" months "&DATEDIF(A1,A2,"md")&" days"

Gives the result : 0 years 4 months 20 days

No comments:

Post a Comment