ABAP Keyword Documentation →  ABAP − Reference →  Calling and leaving program units →  Exiting Program Units → 

Exiting Processing Blocks

Processing blocks can be implicitly exited by

or program-driven exiting, using these statements:

. The onward flow of the program depends on the type of processing block.

In addition to the statements described here, statements that call other units without returning to the caller after the call is made, also end their processing block. These include:

Messages and raised exceptions can also end processing blocks.

Programming Guideline

Only use RETURN to exit procedures

Note

Exiting a procedure by pressing RETURN (or EXIT or CHECK) is the error-free way to end the procedure. Formal parameters for which the pass by value is defined are not passed to the assigned actual parameters only if the procedure terminates after an error (if an exception is raised or a message is sent).




Continue
Normal Exiting of a Processing Block
RETURN
EXIT - processing_block
CHECK - processing_block
STOP