*&---------------------------------------------------------------------*
*& Report ZMM1036
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT zmm1036.
TABLES: a777,konp,konh.
TYPE-POOLS: slis.
INCLUDE:zsy_xy_tcus.
DATA: BEGIN OF i_list OCCURS 0,
kschl LIKE a777-kschl, "条件类型 'PB77'
esokz LIKE a777-esokz, "采购信息类别 0标准
werks LIKE a777-werks, "工厂
ekorg LIKE a777-ekorg, "采购组织
llief LIKE a777-llief, "供应商
name1 LIKE lfa1-name1, "供应商名称
matnr LIKE a777-matnr, "物料编码
maktx LIKE makt-maktx, "物料描述
datab LIKE a777-datab, "开始时间
datbi LIKE a777-datbi, "截止日期
knumh LIKE a777-knumh, "条件记录号 定价记录号
konwa LIKE konp-konwa, "币别
kbetr LIKE konp-kbetr, "金额
kpein LIKE konp-kpein, "定价单位
kmein LIKE konp-kmein, "计量单位
erdat LIKE konh-erdat, "创建日期
loevm_ko LIKE konp-loevm_ko, "删除标记
END OF i_list.
DATA: bdcdata1 LIKE bdcdata OCCURS 0 WITH HEADER LINE."定义BDC内表
DATA: msgtab1 LIKE zbdcmsgcoll OCCURS 0 WITH HEADER LINE.
DATA: m_have TYPE i.
*ALV output data
DATA: alv_fieldcat TYPE slis_t_fieldcat_alv,
alv_layout TYPE slis_layout_alv,
sortcat TYPE slis_t_sortinfo_alv,
stru_disvar TYPE disvariant,
fieldcat TYPE slis_t_fieldcat_alv.
SELECTION-SCREEN BEGIN OF BLOCK bl1 WITH FRAME TITLE text-bl1.
SELECT-OPTIONS:
zmatnr FOR a777-matnr, "物料编码
zllief FOR a777-llief, "供应商
zwerks FOR a777-werks, "工厂
zekorg FOR a777-ekorg, "采购组织
zerdat FOR konh-erdat. "创建日期
PARAMETERS: zscbj AS CHECKBOX . "删除标记
SELECTION-SCREEN END OF BLOCK bl1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-b01.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETER r1 RADIOBUTTON GROUP rad1 USER-COMMAND f1.
SELECTION-SCREEN COMMENT 8(20) text-r01 FOR FIELD r1.
PARAMETER r2 RADIOBUTTON GROUP rad1.
SELECTION-SCREEN COMMENT 30(30) text-r02 FOR FIELD r2.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK b2.
INITIALIZATION.
r1 = 'X'.
START-OF-SELECTION.
PERFORM sub_get_data.
PERFORM sub_process_data.
IF m_have = 0 .
MESSAGE '您查找的数据未在数据库中找到,请检查您提取数据的条件是否正确,谢谢您的使用!' TYPE 'I' .
EXIT.
ENDIF.
END-OF-SELECTION .
PERFORM sub_display_data .
*&---------------------------------------------------------------------*
*& Form SUB_GET_DATA
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
FORM sub_get_data .
m_have = 0.
SELECT a777~kschl "条件类型 'PB77'
a777~esokz
a777~werks "工厂
a777~ekorg "采购组织
a777~llief "供应商
* lfa1~name1 "供应商名称
a777~matnr "物料编码
* makt~maktx "物料描述
a777~datab "开始时间
a777~datbi "截止日期
a777~knumh
ABAP_ALV_事件调用标准Tcode_ZMM1036
最新推荐文章于 2024-04-03 11:02:31 发布
本文详细介绍了如何在自定义事务代码ZMM1036中调用ABAP List Viewer (ALV) 的事件,以实现对数据的自定义处理和增强功能。通过实例展示了如何在ALV生成后触发事件,以及如何利用这些事件进行交互操作,如行选择、单元格修改等。
摘要由CSDN通过智能技术生成