I am using the following code to get Job name and Job number, for one of my tool I need to capture the Date and Time at which the job started execution. Please tell me how to get that information.
/* REXX */
TCB = PTR(540)
TIOT= PTR(TCB+12)
JNAM= STG(TIOT,8)
SNAM= STG(TIOT+8,8)
PSNAM = STG(TIOT+16,8)
JSCB= PTR(TCB+180)
PNAM= STG(JSCB+360,8)
SSIB= PTR(JSCB+316)
JNUM= STG(SSIB+12,8)
SAY 'JOB NAME:' JNAM
SAY 'PROC STEP NAME:' PSNAM
SAY 'STEP NAME :' SNAM
SAY 'PROGRAM NAME:' PNAM
SAY 'JOB NUMBER:' JNUM
EXIT(0)
PTR: RETURN C2D(STORAGE(D2X(ARG(1)),4))
STG: RETURN STORAGE(D2X(ARG(1)),ARG(2))
/* REXX */
TCB = PTR(540)
TIOT= PTR(TCB+12)
JNAM= STG(TIOT,8)
SNAM= STG(TIOT+8,8)
PSNAM = STG(TIOT+16,8)
JSCB= PTR(TCB+180)
PNAM= STG(JSCB+360,8)
SSIB= PTR(JSCB+316)
JNUM= STG(SSIB+12,8)
SAY 'JOB NAME:' JNAM
SAY 'PROC STEP NAME:' PSNAM
SAY 'STEP NAME :' SNAM
SAY 'PROGRAM NAME:' PNAM
SAY 'JOB NUMBER:' JNUM
EXIT(0)
PTR: RETURN C2D(STORAGE(D2X(ARG(1)),4))
STG: RETURN STORAGE(D2X(ARG(1)),ARG(2))