Code: Alles auswählen.
CALL METHOD editor->get_text_as_r3table
exporting
ONLY_WHEN_MODIFIED = 1
IMPORTING
table = g_mytable
is_modified = im
EXCEPTIONS
OTHERS = 1.
IF sy-subrc NE 0.
CALL FUNCTION 'POPUP_TO_INFORM'
EXPORTING
titel = g_repid
txt2 = 'Get_Text_As_R3Table Failed'
txt1 = 'Unable to Store SQL'.
Leave Program.
ENDIF.
describe table g_mytable lines anzahl_zeilen.
Code: Alles auswählen.
CALL METHOD editor->get_text_as_r3table
EXPORTING
ONLY_WHEN_MODIFIED = 0
IMPORTING
table = g_mytable
is_modified = im
EXCEPTIONS
OTHERS = 1.
IF sy-subrc NE 0.
CALL FUNCTION 'POPUP_TO_INFORM'
EXPORTING
titel = g_repid
txt2 = 'Get_Text_As_R3Table Failed'
txt1 = 'Unable to Store SQL'.
Leave Program.
ENDIF.
CALL METHOD cl_gui_cfw=>flush.
Code: Alles auswählen.
CALL METHOD get_textstream
EXPORTING
only_when_modified = cl_gui_textedit=>false
IMPORTING
text = lv_string
is_modified = lv_is_mod
EXCEPTIONS
error_cntl_call_method = 1
not_supported_by_gui = 2
OTHERS = 3.
IF sy-subrc EQ 0.
* flush is required for working on the content
CALL METHOD cl_gui_cfw=>flush
EXCEPTIONS
cntl_system_error = 1
cntl_error = 2
OTHERS = 3.
IF sy-subrc NE 0.
MESSAGE e052.
* Fehler bei der Aktualisierung der Flush-Queue.
ENDIF.
Code: Alles auswählen.
SPLIT ... AT cl_abap_char_utilities=>Cr_lf INTO TABLE ...