LEAVE

Basic form 7

LEAVE.

Effect

Leaves the "CALL mode" (introduced by: CALL TRANSACTION, CALL DIALOG, SUBMIT ... AND RETURN) and returns directly to where the call was made.

Exception: LEAVE TO LIST-PROCESSING

If the system field SY-CALLD is blank, the system ignores the LEAVE statement. If a program is started using LEAVE TO TRANSACTION or using a transaction code, SY-CALLD is empty. If the system is processing batch input folders, SY-CALLD is also empty. For this reason, the behavior of the LEAVE statement is context- specific and use of the statement should be avoided where possible. Use LEAVE PROGRAM, LEAVE SCREEN und LEAVE LIST-PROCESS ING instead.

  1. CALL TRANSACTION tcod:
    Return from the called transaction tcod. Processing continues after "CALL TRANSACTION ...".


  2. CALL DIALOG dial:
    Return from the called dialog module dial. The IMPORT objects of the calling program are passed. Processing continues after "CALL DIALOG ...".


  3. SUBMIT prog AND RETURN:
    Return from the called program prog. Processing continues after the call to "SUBMIT prog ...".


  4. LEAVE TO LIST-PROCESSING AND RETURN TO SCREEN scr:
    Return from list processing. The screen scr is reprocessed.


Note

LEAVE is not required if you use standard F keys in the list processing (F3=Back and F15=Exit).

Related

LEAVE PROGRAM, LEAVE SCREEN, LEAVE LIST-PROCESSING.