Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Control scrolling in ALV OO

oleg_sukharenko
Explorer
0 Kudos
384

I have three custom containers on the same screen. One is on the top and two are on the bottom next to each other. When a user double clicks on a record in the top one, two in the bottom are showing corresponding data. My problem is, when I scroll down couple of pages of the top one and double click on a record the u201CCALL METHOD grid_m->set_scroll_info_via_id" is not working. It does work before double click very first time, but as soon as I double click and go to handler, something getting off. Note: I am using u201CLEAVE TO SCREENu201D from u201CEVENT HANDLERu201Cto go back to PBO of the screen and I recreate ALV list objects in PBO.

Here is my code:

PBO Moduke of the screen 0010

<<<MODULE alv_displayd OUTPUT.

CALL METHOD grid_m->set_scroll_info_via_id

EXPORTING

is_row_info = g_row

is_col_info = g_col

is_row_no = g_roid.

ENDMODULE. " alv_display OUTPUT

<<<Double click handler METHOD

METHOD handle_double_click.

DATA: wa_out_master LIKE gv_out_master.

CLEAR: v_row,v_column,v_row_num.

g_row = v_row = e_row.

g_col = v_column = e_column.

g_roid = v_row_num = es_row_no.

LEAVE TO SCREEN '0010'.

ENDMETHOD. "handle_double_click

Any suggestions?

1 REPLY 1

Sandra_Rossi
Active Contributor
0 Kudos
172

If the double-click is not a system event (so doesn't trigger the PAI), then you'll probably have to call cl_gui_cfw=>flush method to send info to frontend.

You may also need to call refresh_table_display method but I'm not sure whether it's needed or not for scroll* method.