SAP NetWeaver AS ABAP Release 740, ©Copyright 2014 SAP AG. All rights reserved.
ABAP Keyword Documentation → ABAP − Reference → Calling and leaving program units → Exiting Program Units → Exiting Loops →Syntax
CONTINUE.
Effect
The CONTINUE statement can only be used in loops. If it is used, the current loop pass is ended immediately and the program flow is continued with the next loop pass.
Example
A loop pass is exited using CONTINUE if the loop index sy-index is an odd number.
DATA remainder TYPE i.
DO 20 TIMES.
remainder = sy-index MOD 2.
IF remainder <> 0.
CONTINUE.
ENDIF.
cl_demo_output=>write_text( |{ sy-index }| ).
ENDDO.
cl_demo_output=>display( ).