Code: Alles auswählen.
*&---------------------------------------------------------------------*
*& Report ZTEST_PRETTY_PRINT
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT ztest_pretty_print.
DATA:
pname TYPE rpy_prog-progname VALUE 'ZTEST_PP',
s1 TYPE TABLE OF abapsource,
s2 TYPE TABLE OF abaptxt255,
ntext TYPE TABLE OF abaptxt255.
CALL FUNCTION 'RPY_PROGRAM_READ'
EXPORTING
* LANGUAGE = SY-LANGU
program_name = pname
* WITH_INCLUDELIST = 'X'
* ONLY_SOURCE = ' '
* ONLY_TEXTS = ' '
* READ_LATEST_VERSION = ' '
* WITH_LOWERCASE = ' '
* IMPORTING
* PROG_INF =
TABLES
* INCLUDE_TAB =
source = s1
source_extended = s2
* TEXTELEMENTS =
EXCEPTIONS
cancelled = 1
not_found = 2
permission_error = 3
OTHERS = 4.
IF sy-subrc <> 0.
EXIT.
ENDIF.
CALL FUNCTION 'PRETTY_PRINTER'
EXPORTING
inctoo = 'X'
TABLES
ntext = ntext
otext = s2
EXCEPTIONS
enqueue_table_full = 1
include_enqueued = 2
include_readerror = 3
include_writeerror = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.