ABAP程序调用之SUBMIT
2016-01-28 12:55
267 查看
(1) 调用其他程序:
SUBMIT zpcppmd001_idoc AND RETURN.
(2) 调用其他程序参数传递参数:
当被调用的程序的屏幕有输入参数时:
SUBMIT zreport
with p_param1 = 'value1'
with
p_param2 = 'value2'.
注:p_param1、p_param2
为被调程序parameter 或者select-option中定义的东西
当要传递一个内表到被调用的程序时,需要用SAP MEMORY或者ABAP MEMORY:
在调用的程序中:EXPORT it_tab
TO MEMORY 'Z_MEMORY'.
在被调用的程序中:IMPORT T_ITAB
FROM
MEMORY 'Z_MEMORY'.
(3) 更复杂一点的可以用文件临时存储数据:
带select-options程序的Submit的用法
*Code used to populate 'select-options' & execute report
DATA: seltab type table of rsparams,
seltab_wa like line of seltab.
seltab_wa-selname = 'PNPPERNR'.
seltab_wa-sign = 'I'.
seltab_wa-option = 'EQ'.
* load each personnel number accessed from the structure into
* parameters to be used in the report
loop at pnppernr.
seltab_wa-low = pnppernr-low.
append seltab_wa to seltab.
endloop.
SUBMIT zreport with selection-table seltab
via selection-screen.
其他情况
*Submit report and return to current program afterwards
SUBMIT zreport AND RETURN.
*Submit report via its own selection screen
SUBMIT zreport VIA SELECTION-SCREEN.
*Submit report using selection screen variant
SUBMIT zreport USING SELECTION-SET 'VARIANT1'.
SUBMIT zpcppmd001_idoc AND RETURN.
(2) 调用其他程序参数传递参数:
当被调用的程序的屏幕有输入参数时:
SUBMIT zreport
with p_param1 = 'value1'
with
p_param2 = 'value2'.
注:p_param1、p_param2
为被调程序parameter 或者select-option中定义的东西
当要传递一个内表到被调用的程序时,需要用SAP MEMORY或者ABAP MEMORY:
在调用的程序中:EXPORT it_tab
TO MEMORY 'Z_MEMORY'.
在被调用的程序中:IMPORT T_ITAB
FROM
MEMORY 'Z_MEMORY'.
(3) 更复杂一点的可以用文件临时存储数据:
带select-options程序的Submit的用法
*Code used to populate 'select-options' & execute report
DATA: seltab type table of rsparams,
seltab_wa like line of seltab.
seltab_wa-selname = 'PNPPERNR'.
seltab_wa-sign = 'I'.
seltab_wa-option = 'EQ'.
* load each personnel number accessed from the structure into
* parameters to be used in the report
loop at pnppernr.
seltab_wa-low = pnppernr-low.
append seltab_wa to seltab.
endloop.
SUBMIT zreport with selection-table seltab
via selection-screen.
其他情况
*Submit report and return to current program afterwards
SUBMIT zreport AND RETURN.
*Submit report via its own selection screen
SUBMIT zreport VIA SELECTION-SCREEN.
*Submit report using selection screen variant
SUBMIT zreport USING SELECTION-SET 'VARIANT1'.
相关文章推荐
- linux下编译php扩展:php7安装redis为例
- learn python the hard way(笨办法学python) 练习10
- 详解memcached原理
- Android 混淆详解
- 05、层
- 安卓自定义View进阶-Canvas(2)画布操作
- Visualizing Concurrency in Go--转
- 设计模式 - 单例模式mysql数据库操作类
- 2015 最受开发者欢迎的开发工具和服务 TOP 50(上)
- poj 1611The suspects
- 如何管理好测试团队
- Struts2 拦截器具体配置过程
- Best Time to Buy and Sell Stock II
- find 命令
- 个人对于lower_bound的理解
- 读书笔记 精通CSS 高级Web标准解决方案(第2版)4~8章
- Git 忽略一些文件不加入版本控制
- HDU1495 非常可乐(BFS)
- 在linux系统上如何连接远程服务器
- 腾讯确认放弃开发Win10 Mobile QQ, 太给力了