Dabei handelt es sich (in einer Tabelle) um ein Feld vom Typ "Button" 😉
Code: Alles auswählen.
if column = 'KZ_LANGTEXT'.
if zt_saldenliste-KZ_LANGTEXT = 'X'.
concatenate 'Langtext aus Beleg ' zt_saldenliste-belnr into z_text respecting blanks.
CALL FUNCTION 'RECA_GUI_TEXTEDIT_POPUP'
EXPORTING
ID_TDOBJECT = zt_saldenliste-langtext_TDOBJECT
ID_TDNAME = zt_saldenliste-langtext_TDNAME
ID_TDID = zt_saldenliste-langtext_TDID
ID_TDSPRAS = zt_saldenliste-langtext_TDSPRAS
ID_ACTIVITY = '02'
ID_TITLE = Z_TEXT
EXCEPTIONS
TEXT_INCONSISTENT = 1
FOREIGN_LOCK = 2
OTHERS = 3.
endif.
endif.
Code: Alles auswählen.
DATA: it_editor TYPE STANDARD TABLE OF char1024.
* Button Pos 2 Länge 20, sendet Kommando 'CMD_SHOW'
SELECTION-SCREEN: PUSHBUTTON 2(20) btn1 USER-COMMAND cmd_show.
* Popup-Fenster (Selektionsbild 100) deklarieren
SELECTION-SCREEN BEGIN OF SCREEN 100 TITLE title.
SELECTION-SCREEN END OF SCREEN 100.
INITIALIZATION.
* Fenstertitel
title = 'Texteditor'.
* Button-Text setzen
btn1 = |{ icon_activity }Popup anzeigen|.
AT SELECTION-SCREEN.
* wenn Button-Kommando 'CMD_SHOW'
IF sy-ucomm = 'CMD_SHOW'.
* cl_gui_container=>screen1 == SELECTION-SCREEN 100
DATA(o_edit) = NEW cl_gui_textedit( wordwrap_mode = cl_gui_textedit=>wordwrap_at_windowborder
wordwrap_to_linebreak_mode = cl_gui_textedit=>true
parent = cl_gui_container=>screen1 ).
* feste Zeichenbreite
o_edit->set_font_fixed( mode = cl_gui_textedit=>true ).
* Popup-Fenster (Selektionsbild 100) anzeigen -> cl_gui_container=>screen1 wird erzeugt
CALL SELECTION-SCREEN 100 STARTING AT 10 5 ENDING AT 100 20.
* Text aus dem Editor holen
o_edit->get_text_as_stream( IMPORTING text = it_editor ).
* Editorobjekt freigeben
FREE: o_edit.
ENDIF.
START-OF-SELECTION.
LOOP AT it_editor ASSIGNING FIELD-SYMBOL(<l>).
WRITE: / <l>.
ENDLOOP.
Code: Alles auswählen.
rv_own_navigation = abap_false.
IF SY-UNAME <> 'deinBenutzer'.RETURN.ENDIF.
BREAK-POINT.
Code: Alles auswählen.
IF cr61t-lsmod = space.
IF ZCL_MD06_ENHANCEMENTS=>MD06_NAVIGATION( is_mdke = mdkex
iv_fname = am61r-fname ).
RETURN.
ENDIF.
ENDIF.