Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

method grid1->get_selected_rows

where is the mistake in this coding

data: grid1 TYPE REF TO cl_gui_alv_grid.

MODULE user_command_0100 INPUT.

case ok_code.

MOVE: lips-vbeln TO wa_input-vbeln,

lips-posnr TO wa_input-posnr,

lips-sernr TO wa_input-sernr.

APPEND wa_input TO lt_input.

CALL METHOD grid1->set_table_for_first_display

EXPORTING

i_structure_name = 'ZSERIALNO_INPUT'

is_layout = gs_layout

IT_TOOLBAR_EXCLUDING = LT_EXCLUDE

CHANGING

it_outtab = lt_zserialno_input

it_fieldcatalog = lt_fct

EXCEPTIONS

invalid_parameter_combination = 1

program_error = 2

too_many_lines = 3

OTHERS = 4.

when 'DELETE'.

CALL METHOD grid1->get_selected_rows

IMPORTING

et_index_rows = lt_selected_rows.

endcase.

endmodule.

yesterday it worked but now the table lt_selected_rows is always initial.

replied

while creating the Grid object did you set the

parameter to 'X'

create object grid
      exporting
         i_parent = custom_container
         i_appl_events = 'X'. "Set this...

if not Set it and Try it once.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question