Code: Alles auswählen.
call method GO_ALV->REGISTER_EDIT_EVENT
exporting
I_EVENT_ID = CL_GUI_ALV_GRID=>MC_EVT_MODIFIED.
* Enter
call method GO_ALV->REGISTER_EDIT_EVENT
exporting
I_EVENT_ID = CL_GUI_ALV_GRID=>MC_EVT_ENTER.
Code: Alles auswählen.
create object GO_EVT_RECEIV_ALV.
set handler GO_EVT_RECEIV_ALV->HANDLE_USER_COMMAND for GO_ALV.
set handler GO_EVT_RECEIV_ALV->HANDLE_TOOLBAR for GO_ALV.
set handler GO_EVT_RECEIV_ALV->HANDLE_DATA_CHANGED for GO_ALV.
set handler GO_EVT_RECEIV_ALV->HANDLE_DATA_CHANGED_FINISHED for GO_ALV.
Code: Alles auswählen.
class LCL_EVENT_RECEIVER_ALV definition.
public section.
methods:
HANDLE_TOOLBAR
for event TOOLBAR of CL_GUI_ALV_GRID
importing E_OBJECT E_INTERACTIVE,
HANDLE_USER_COMMAND
for event USER_COMMAND of CL_GUI_ALV_GRID
importing E_UCOMM,
HANDLE_DATA_CHANGED
for event DATA_CHANGED of CL_GUI_ALV_GRID
importing ER_DATA_CHANGED,
HANDLE_DATA_CHANGED_FINISHED
for event DATA_CHANGED_FINISHED of CL_GUI_ALV_GRID
importing E_MODIFIED
ET_GOOD_CELLS.
endclass. "LCL_EVENT_RECEIVER_ALVDEFINITION
Code: Alles auswählen.
method HANDLE_DATA_CHANGED_FINISHED.
perform no_edit using E_MODIFIED.
ET_GOOD_CELLS.
endmethod.
Folgende Benutzer bedankten sich beim Autor jensschladitz für den Beitrag:
Nadine_2706