*---bapi return
delete it_return where type = 'S' or type = 'W' or type = 'I'.
if it_return is initial.
"返回正确消息
call function 'BAPI_TRANSACTION_COMMIT'
exporting
wait = 'X'.
else.
read table it_return into lw_return with key type = 'E'.
if sy-subrc = 0.
"返回错误消息
endif.
call function 'BAPI_TRANSACTION_ROLLBACK' .
endif.
评论