Adds days to a datetime.

DateTime = SRP_DateTime("AddDays", Datetime, Days)

Returns

A new datetime.

Parameters

ParameterDescription
DatetimeA datetime in OI internal format. (REQUIRED)
DaysThe number of days to add. (REQUIRED)

Remarks

The "AddDays" service calculates a new datetime by adding the given number of days to an existing datetime. You can pass whole numbers or decimal numbers. You can also pass negative values to subtract days.

Examples

// Add 10 days to the current datetime
NewDateTime = SRP_DateTime("AddDays", DateTime(), 10)

// Add a day and a half to the current datetime
NewDateTime = SRP_DateTime("AddDays", DateTime(), 1.5)

// Subtract 10 days from the current datetime
NewDateTime = SRP_DateTime("AddDays", DateTime(), -10)

  • No labels