‎2008 Jul 09 8:29 AM
hai ,
I have problem with my interactive alv ,
when i double click the line item the same line item is displaying for all the selections ..
LASS lcl_event_handler IMPLEMENTATION.
METHOD on_double_click.
find out selected line (double click)
READ TABLE i_fd INTO w_fd INDEX e_row-index.
IF sy-subrc NE 0.
MESSAGE i075(bc412). " <-- internal error
EXIT.
ENDIF.
"CLEAR i_popup.
LOOP AT i_trdt INTO w_trdt WHERE deal_number = w_fd-rfha .
IF sy-tabix GT 1.
CLEAR w_trdt-deal_number.
ENDIF.
APPEND w_trdt TO i_popup.
ENDLOOP.
CLEAR : w_fd , w_trdt .
IF i_popup IS NOT INITIAL .
CREATE OBJECT ref_container
EXPORTING
parent =
container_name = 'CONTAINER1'
style =
lifetime = lifetime_default
repid =
dynnr =
no_autodef_progid_dynnr =
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5
others = 6
.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CREATE OBJECT ref_alv
EXPORTING
i_shellstyle = 0
i_lifetime =
i_parent = ref_container
i_appl_events = space
i_parentdbg =
i_applogparent =
i_graphicsparent =
i_name =
i_fcat_complete = space
EXCEPTIONS
error_cntl_create = 1
error_cntl_init = 2
error_cntl_link = 3
error_dp_create = 4
OTHERS = 5
.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
PERFORM form_layout.
PERFORM f_cat.
CALL METHOD ref_alv->refresh_table_display.
CALL METHOD g_alv->refresh_table_display.
ENDIF.
CALL METHOD g_alv->refresh_table_display.
CLEAR i_popup.
ENDMETHOD. "on_double_click
ENDCLASS. "lcl_event_handler IMPLE
Regards,
K,Vinay Kumar
‎2008 Jul 09 8:31 AM
‎2008 Jul 09 9:04 AM
‎2008 Jul 10 9:28 AM
‎2008 Jul 10 9:30 AM
i think clearing the work area before the loop's should solve the problem.
try refresfing the intab tooo
‎2008 Jul 10 9:38 AM
Hi,
Try..
READ TABLE i_fd INTO w_fd INDEX es_row_no-index.
Hope it helps you.
Murthy