miércoles, 19 de diciembre de 2012

EXIT_

EXIT in loops and modularization units


Basic form

EXIT.

Effect

  • Outside loop structures and modularization units (report processing):

    Cancels the report processing and displays the list

Example

TABLES T100. DATA SAP_COUNT TYPE I. SELECT * FROM T100 WHERE SPRSL = SY-LANGU AND ARBGB = 'DS'. WRITE / T100-TEXT. IF T100-TEXT CS 'SAP'. ADD 1 TO SAP_COUNT. IF SAP_COUNT = 3. EXIT. ENDIF. ENDIF. ENDSELECT.

Note

If there are several nested loops, the effect of EXIT is only to leave the current loop. Processing continues after the next END... statement in the next loop up.
Related CONTINUE , CHECK , REJECT , STOP

Index
© SAP AG 1996

No hay comentarios:

Publicar un comentario

Nota: solo los miembros de este blog pueden publicar comentarios.