company logo

Date :: subtractMonths - Subtract month from date value

The function subtracts a number of months from the current date and returns the new date value.

Return value:  Date ( odaba::Date & )

The date contains day, month and year, but not the time.

Implementation details

odaba::Date & Date  :: subtractMonths ( int32 iMonths )

The number of months passed in iMonths is subtracted from the date value. Year may change, when month becomes less than 1. Usually, day remains unchanged, but will be adjusted, when the new month value does not have the resulting day

  • iMonths - Months

    Time span in months.