Xojo.Core.Date.Add

From Xojo Documentation

Method

Xojo.Core.Date.Operator_Add(interval As Xojo.Core.DateInterval) As Xojo.Core.Date

Supported for all project types and targets.

You use the "+" operator to add a Date and a Xojo.Core.DateInterval to get a new Date.

Sample Code

Get the date two months from today:

Var twoMonths As New Xojo.Core.DateInterval
twoMonths.Months = 2 // 2 month interval

// Get date two months from today
Var future As Xojo.Core.Date = Xojo.Core.Date.Now + twoMonths