‎2008 Mar 18 12:53 PM
Hello,
My problem is with a report that displays a ALV Grid.
At click on a field in that alv it calls another transaction. Everything is ok until, inside that transaction, at some points there are several "COMMIT WORK" lines. After the first commit work line, it leaves the called transaction and return to the caller report without executing the code remained after the "COMMIT WORK" line.
How can i tell the report to call that transaction without returning after every commit?
Thanks in advance,
Andrei
‎2008 Mar 18 12:55 PM
Hi ,
Try this code,
FORM user_command USING ucomm LIKE sy-ucomm sel TYPE slis_selfield .
DATA : v_repid LIKE sy-repid.
v_repid = sy-repid.
DATA: lv_ucomm TYPE sy-ucomm,
v_ebeln1 TYPE ekko-ebeln.
lv_ucomm = sy-ucomm.
***REFRESH T_SER.
***REFRESH IT_SER03.
***REFRESH IT_OBJK.
CASE ucomm.
WHEN '&IC1'.
IF sel-fieldname = 'EBELN'.
v_ebeln1 = sel-value.
* READ TABLE it_final INTO wa_final WITH KEY ebeln1 = sel-value.
READ TABLE itab WITH KEY ebeln = sel-value.
unpack v_ebeln1 to v_ebeln1.
SET PARAMETER ID 'BES' FIELD v_ebeln1.
CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.
ENDIF.
ENDCASE.
ENDFORM. "USER_COMMAND
*ENDFORM.Regards,
S.Nehru
‎2008 Mar 18 12:55 PM
Hi ,
Try this code,
FORM user_command USING ucomm LIKE sy-ucomm sel TYPE slis_selfield .
DATA : v_repid LIKE sy-repid.
v_repid = sy-repid.
DATA: lv_ucomm TYPE sy-ucomm,
v_ebeln1 TYPE ekko-ebeln.
lv_ucomm = sy-ucomm.
***REFRESH T_SER.
***REFRESH IT_SER03.
***REFRESH IT_OBJK.
CASE ucomm.
WHEN '&IC1'.
IF sel-fieldname = 'EBELN'.
v_ebeln1 = sel-value.
* READ TABLE it_final INTO wa_final WITH KEY ebeln1 = sel-value.
READ TABLE itab WITH KEY ebeln = sel-value.
unpack v_ebeln1 to v_ebeln1.
SET PARAMETER ID 'BES' FIELD v_ebeln1.
CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.
ENDIF.
ENDCASE.
ENDFORM. "USER_COMMAND
*ENDFORM.Regards,
S.Nehru