Code: Alles auswählen.
LR_SALV_TABLE->GET_SELECTIONS( )->SET_CURRENT_CELL( ... )
Folgende Benutzer bedankten sich beim Autor a-dead-trousers für den Beitrag:
Romaniac
🤓
Code: Alles auswählen.
class ZCL_SALV_TOOL definition
public
inheriting from CL_SALV_CONTROLLER
final
create public .
public section.
class-methods SET_SCROLL_INFO_VIA_ID
importing
!IR_SALV type ref to CL_SALV_TABLE
!IS_COL type LVC_S_COL
!IS_ROW type LVC_S_ROID
!IT_ROWS type LVC_T_ROW .
ENDCLASS.
CLASS ZCL_SALV_TOOL IMPLEMENTATION.
METHOD SET_SCROLL_INFO_VIA_ID.
DATA:
lr_controller TYPE REF TO cl_salv_controller_model,
lr_salv_grid_adapter TYPE REF TO cl_salv_grid_adapter,
lr_grid TYPE REF TO cl_gui_alv_grid.
* Fullscreen Adapter (Down Casting)
lr_controller ?= ir_salv->r_controller.
lr_salv_grid_adapter ?= lr_controller->r_adapter.
* Get the Grid
lr_grid = lr_salv_grid_adapter->get_grid( ).
lr_grid->set_scroll_info_via_id(
* is_row_info =
is_col_info = is_col
is_row_no = is_row
).
lr_grid->set_selected_rows(
it_index_rows = it_rows
* it_row_no =
* is_keep_other_selections =
).
ENDMETHOD.
ENDCLASS.
Im SALV trübt dich deine Erinnerung ganz sicher 😉