Syntax 

DateAdd(interval, number, dateexpr)


Group 

Time/Date 


Description 

Return a Date value a number of intervals from another date. 


Parameters

Description

interval 

This string value indicates which kind of interval to add. 

number 

Add this many intervals. Use a negative value to get an earlier date. 

dateexpr 

Calculate the new date relative to this date value. If this value is Null then Null is returned. 


Interval

Description

yyyy 

Year 

Quarter 

Month 

Day of year 

Day 

Weekday 

ww 

Week 

Hour 

Minute 

Second 


See Also 

DateDiff, DatePart


Example

Sub Main

    Debug.Print DateAdd("yyyy",1,#1/1/2000#) '1/1/2001

End Sub