Any easy way to do this? In VBA I'd normally use dateadd() but since this is Excel, I don't have that function.
The following function does the job:
=DATE(YEAR(A2),MONTH(A2)+B2,MIN(DAY(A2),DAY(DATE(YEAR(A2),MONTH(A2)+B2+1,0))))
For example:
Date Add Months Result
8/1/2012 6 =DATE(YEAR(A2),MONTH(A2)+B2,MIN(DAY(A2),DAY(DATE(YEAR(A2),MONTH(A2)+B2+1,0))))
Result:
Date Add Months Result
8/1/2012 6 2/1/2013
You could also use the EDATE worksheet function. For example EDATE(DATE(2012,8,1),6) returns February 1, 2013.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With