CANCEL (Cancel Task) Macro
Issuing the CANCEL macro in a subtask abnormally terminates the subtask without branching to any abnormal termination routine.
A CANCEL ALL macro issued in a subtask, or a CANCEL issued in the main task, abnormally terminates all processing in the partition (job). Job termination in multitasking causes all abnormal termination exits (via STXIT AB) to be taken for each task except the one that issued the CANCEL macro. Once these exits are taken, the job is terminated. System messages (using the subtask name) are issued to identify each of the terminated subtasks.
If the CANCEL macro is issued without an operand, you cannot code a comment unless this comment begins with a comma. If CANCEL ALL is issued, you can code a comment as usual.
If
the DUMP option was specified and SYSLST is assigned, a system dump
occurs
- if a CANCEL ALL macro is issued by a subtask, or
- if a CANCEL macro is issued by a main task with subtasks attached.
Note: If your program uses VSAM files, ensure that these files
are closed before you issue this macro.
Format
Requirements for the caller
- AMODE:
- 24 or 31
- RMODE:
- 24 or ANY
- ASC Mode:
- Primary