DT_SUBTRACT

The DT_SUBTRACT function decrements an array of IDLDT date/time variables by a constant amount. Each value is subtracted from the corresponding component, then the result is renormalized with JUL_TO_DT.The result is an array of IDLDT date/time structures, decremented by the desired amount.

Calling Sequence

Result = DT_SUBTRACT( Dt_var )

Arguments

Dt_var

An array of IDLDT date/time structures.

Keyword

COMPRESS

Eliminate holidays (see !HOLIDAYS).

DAY

The offset in days.

HOUR

The offset in hours.

MINUTE

The offset in minutes.

SECOND

The offset in seconds.

YEAR

The offset in years.

Example

PRINT, DT_SUBTRACT( TODAY(), DAY=1, YEAR=3)
; Takes 1 from today's dayand 3 from today's year.

See Also

IDLDT__DEFINE