CONT1 TYPE REF TO CL_GUI_CUSTOM_CONTAINER, IT_FDCAT TYPE LVC_T_FCAT, WA_FDCAT TYPE LVC_S_FCAT, IT_LAYO TYPE TABLE OF LVC_S_LAYO, WA_LAYO TYPE LVC_S_LAYO, handll TYPE REF TO event_class, CREATE OBJECT cont1 EXPORTING container_name = 'CON2'. CREATE OBJECT grid1 EXPORTING i_parent = cont1. -------------------------------------------display alv------------------------------------------CALL METHOD grid2->set_table_for_first_display EXPORTING i_save = i_save is_layout = is_layout CHANGING it_outtab = it_output it_fieldcatalog = it_fdcat. *it_output - Table which needs to be displayed -------------------------------------------editable alv code copy paste-------------------------CALL METHOD grid2->REGISTER_EDIT_EVENT EXPORTING I_EVENT_ID = CL_GUI_ALV_GRID=>MC_EVT_MODIFIED EXCEPTIONS ERROR = 1 OTHERS = 2. CALL METHOD grid2->CHECK_CHANGED_DATA. *it_output will now contain changed data --------------------------------------------INTERACTIVE ALV DOUBLE CLICK-------------------------class event_class defination. public section. methods: handle_double_clicking for event DOUBLE_CLICK of CL_GUI_ALV_GRID import ing E_ROW. endclass. class event_class implementation. method: handle_double_clicking. data : wa_ot type it_output."as displayed in alv read table it-output index E_ROW-index into wa_ot." double clicked entire line i s now in wa_ot
*perform any operations with data obtained in wa_ot
*like calling another alv *select * from table * where fields = wa_ot-data *CALL METHOD grid2->set_table_for_first_display * CHANGING * it_outtab = it_output * it_fieldcatalog = it_fdcat. DATA : handll type ref to event_class create object handll . set handler handll->handle_double_clicking FOR GRID2. double clicking is required