*&---------------------------------------------------------------------*
*& Form frm_retrieve_data
*&---------------------------------------------------------------------*
* text:抓取report painter报表信息
*----------------------------------------------------------------------*
FORM frm_retrieve_data .
DATA:lt_params TYPE STANDARD TABLE OF alv_s_param_wp,
lwa_params TYPE alv_s_param_wp,
lwa_msg LIKE LINE OF gt_msg,
lv_dcpfm TYPE xudcpfm.
CLEAR:gt_data,gt_msg.
* 设置report painter报表的选择屏幕参数与默认值
lwa_params-pname = '$PARAMETER[$ZRYEAR0'.
lwa_params-pvalue = sy-datum+0(4).
APPEND lwa_params TO lt_params .
lwa_params-pname = '$PARAMETER[$ZBUKRS0'.
lwa_params-pvalue = 'JNPC'.
APPEND lwa_params TO lt_params .
lwa_params-pname = '$PARAMETER[$ZBUKRS1'.
lwa_params-pvalue = 'JNPC'.
APPEND lwa_params TO lt_params .
lwa_params-pname = '$PARAMETER[$ZF-RP00'.
lwa_params-pvalue = sy-datum+4(2).
APPEND lwa_params TO lt_params .
CALL FUNCTION 'CRIF_RW_WEB_CALL_REPORT'
EXPORTING
i_report_group = 'JNZ1'
TABLES
it_params = lt_params
et_data = gt_data
et_messages = gt_msg.
LOOP AT gt_msg INTO lwa_msg
WHERE type = 'E' OR type = 'A'.
gv_flg = cns_yes.
EXIT.
ENDLOOP.
IF gv_flg IS INITIAL AND
gt_data IS INITIAL.
gv_flg = cns_nodata.
ENDIF.
ENDFORM. " frm_retrieve_data
阅读(2246) | 评论(0) | 转发(0) |