company logo

DateTime :: subtractYears - Subtract years from date value

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

Return value:  Time stamp ( odaba::DateTime & )

A time stamp combines date and time

Implementation details

odaba::DateTime & DateTime  :: subtractYears ( int32 iYears )

The number of years passed in iYears is subtracted from the date value. Month and day remain unchanged, except for February 29th, which might be adjusted to February 28th.

  • iYears - Year number

    Number of years or year number.