What is ABAP subroutine
A subroutine is a reusable section of code. It is like a mini-program that can be called from another point in your program. Within it you can define variables, execute statements, compute results, and write output. To define a subroutine, use the form statement to indicate the start of a subroutine, and use endform to indicate the end of the subroutine. The name of a subroutine cannot exceed 30 characters.
To call a subroutine, use the perform statement.
report ztx1706. write: / 'Before call 1'. perform sub1. write: / 'Before call 2'. perform sub1. write: / 'After calls'. form sub1. write: / 'Inside sub1'. endform.
Popularity: 6% [?]
Tags: ABAP, Subroutine






