FM实现F4帮助系列四:弹出框多筛选条件的搜索帮助(自定义筛选字段)
函数:
效果图:
本例子代码:
*&-------------------------------------------------------------------
REPORT zlm_test_044.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: p_matnr TYPE matnr.
SELECTION-SCREEN END OF BLOCK b1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_matnr.
*&---------------------------------------------------------------------*
*& Form frm_f4
*&---------------------------------------------------------------------*
*
*----------------------------------------------------------------------*
FORM frm_f4.
werks TYPE werks_d,
matnr TYPE matnr,
maktx TYPE maktx,
END OF values.
DATA: values_tab
SELECT marc~werks makt~matnr makt~maktx
FROM makt
INNER JOIN marc ON marc~matnr = makt~matnr
INTO CORRESPONDING FIELDS OF TABLE values_tab.
retfield
dynpprog
dynpnr
dynprofield = 'MAKTX'
value_org = 'S'
callback_form = 'FRM_LIST' "Form for callback before F4 start (-> long docu)
value_tab = values_tab.
ENDFORM. "frm_f4
*&-------------------------------------------------------------------
*& 设置显示模式
*&-------------------------------------------------------------------
FORM frm_list TABLES record_tab STRUCTURE seahlpres
CHANGING shlp TYPE shlp_descr
shlp-intdescr-dialogtype = 'C'.
callcontrol-maxrecords = '50'. "最大显示数量
ENDFORM. "FRM_LIST
另外一个F4增强的例子,也是添加筛选字段:
http://blog.sina.com.cn/s/blog_c0978c9b0101h1qf.html
标签:matnr,F4,框多,frm,values,tab,TYPE,FM From: https://blog.51cto.com/u_15680210/5751444