addMonths

addMonths(months)

Adds the specified number of months to the value of this instance.

ParameterTypeDescription
monthsintA number of months. The months parameter can be negative or positive.

Returns: A DateTime object whose value is the sum of the date and time represented by this instance and months.