vba create a date from day month year code example
Example: vba add month to date
MsgBox DateAdd("m", 1, "1995-01-31") ' 1995-02-28
MsgBox DateAdd("m", -2, "1995-01-31") ' 1994-11-30
MsgBox DateAdd("yyyy", 2, "1995-01-31") ' 1997-01-31