Previous Topic: TLMDATE NUM_DAYS Macro—Days Between DatesNext Topic: TLMDATE PARM Macro—Define Parameter List


TLMDATE OPEN Macro—Initialize Date Routines

Use the OPEN form of TLMDATE to initialize date routines for processing. This includes GETMAINing storage and obtaining the Preferred date format. TLMDATE OPEN must be issued before any other forms of the macro will execute successfully. OPEN establishes the ANCHOR used by all other calls.

This function uses registers 0, 1, 14 and 15. These registers cannot be used to pass information into the macro.

This macro has the following format:

label TLMDATE OPEN ,FMT=format
,ANCHOR=anchor
,PARM=plist
[,NORMAL=branch]
[,ERROR=branch]
[,FAIL=branch]
FMT=format

Specifies a 10-byte field containing a date pattern.

Type: RX-type label, (Rn), or constant (quotes)

ANCHOR=anchor

Points to the label specified by the ANCHOR form of the TLMDATE macro.

Type: RX-type label or (Rn)

PARM=plist

Points to the label specified by the PARM form of the TLMDATE macro.

Type: RX-type label or (Rn)

NORMAL=branch

(Optional). Specifies the instruction to receive control on return from the CTSDATE module when no errors occurred. If not defined, the next instruction after the macro is executed.

Type: RX-type label

ERROR=branch

(Optional) Specifies the instruction to receive control on return from the CTSDATE module when a date or range error occurred. If not defined, the next instruction after the macro is executed.

Type: RX-type label

FAIL=branch

(Optional) Specifies the instruction to receive control on return from the CTSDATE module when a critical error has occurred. If not defined, the next instruction after the macro is executed.

Type: RX-type label

Example: TLMDATE OPEN Macro

                                                                  Pos. 72
                                                                  |
TLMDATE  OPEN,FMT=DATEFMT,ANCHOR=DAANCHOR,PARM=DATEPARM,          X
      ERROR=ABEND10,FAIL=ABEND10