*DATA: BEGIN OF lr_alv_data OCCURS 0. * INCLUDE STRUCTURE stpov_alv. *DATA: info(3) TYPE c, * END OF lr_alv_data. FIELD-SYMBOLS : <lt_alv_data> TYPE ANY TABLE . DATA:lr_alv_data TYPE REF TO data. cl_salv_bs_runtime_info=>set( EXPORTING display = abap_false metadata = abap_false data = abap_true ). FIELD-SYMBOLS : <lt_data> TYPE any. "LIKE LINE OF it_tab . CLEAR lr_alv_data. UNASSIGN <lt_alv_data>. SUBMIT rcs15001 WITH pm_idnrk = '0DMA-174000' WITH pm_werks = '1000' WITH PM_MEHRS = 'X' AND RETURN. TRY. cl_salv_bs_runtime_info=>get_data_ref( IMPORTING r_data = lr_alv_data ). ASSIGN lr_alv_data->* TO <lt_alv_data>. CATCH cx_salv_bs_sc_runtime_info. MESSAGE 'Unable to retrieve ALV data! Please try other conditions.' TYPE 'E'. ENDTRY. cl_salv_bs_runtime_info=>clear_all( ). IF <lt_alv_data> IS ASSIGNED. UNASSIGN <lt_data>. LOOP AT <lt_alv_data> ASSIGNING <lt_data>."即所需要内表数据 * MOVE-CORRESPONDING <lt_data> TO ls_data. * APPEND ls_data TO lt_data. * CLEAR ls_data. ENDLOOP. ENDIF. BREAK-POINT.
标签:info,报表,data,获取,lr,bs,alv,TYPE,数据 From: https://www.cnblogs.com/chrisssyuan/p/17433264.html