AMT Help Files
Home Development Command Translation CICS Commands HANDLE ABEND

HANDLE ABEND

COBOL Java
EXEC CICS HANDLE ABEND ibmCics.handleAbend
EXEC CICS HANDLE ABEND CANCEL ibmCics.cancelHandleAbend

Syntax

ibmCics.handleAbend ( <CobolPerform>, new CicsHandleAidItem(CicsHandleAidOption.TRIGGER ));

LABEL option

ibmCics.handleAbend ( <CobolPerform>, new CicsHandleAidItem(CicsHandleAidOption.TRIGGER, <Label>, <Section> ));

PROGRAM option

ibmCics.handleAbend ( <CobolPerform>, new CicsHandleAidItem(CicsHandleAidOption.TRIGGERPROGRAM, <Program> ));

CANCEL option

ibmCics.cancelHandleAbend ();

Parameter(s)

<CobolPerform>
The AMT Cobol Perform object, this is 'cobolPerformBase' in programs.
<CicsHandleAidOption>
The Aid option from the CicsHandleAidOption enum. TRIGGERPROGRAM to pass control to a program, TRIGGER for other handle abend options.
<Label>
The label to perform when the task ended abnormally.
<Section>
The section in the program where the label is located.
<Program>
The program to perform when the task ended abnormally.

Example(s)

COBOL Java
EXEC CICS
    HANDLE ABEND
END-EXEC.
                
ibmCics.handleAbend(cobolPerformBase,
    new CicsHandleAidItem(CicsHandleAidOption.TRIGGER));
                
EXEC CICS
    HANDLE ABEND
    LABEL (0100-ABEND-HANDLER)
END-EXEC.
                
ibmCics.handleAbend(cobolPerformBase, 
    new CicsHandleAidItem(CicsHandleAidOption.TRIGGER, LABEL_0100_ABEND_HANDLER, "MAIN"));
                
EXEC CICS
    HANDLE ABEND
    PROGRAM ('OOPS')
END-EXEC.
                
ibmCics.handleAbend(cobolPerformBase, 
    new CicsHandleAidItem(CicsHandleAidOption.TRIGGERPROGRAM, "OOPS"));
                
EXEC CICS
    HANDLE ABEND
        CANCEL
END-EXEC.
                
ibmCics.cancelHandleAbend();
                

Contents

 Go to top