批量修改生產BOM

REPORT Y_TEST1 .


  • Title : ZPPR101 *
  • Application : PP   *
  • Subject : 批量更改BOM组件 *
  • Requested by : PP *
  • Execution : any time *
  • Ref no: : B221 *
  • Author : rainy *
  • Req Date : 20150701 *

  • Production Order Variance Report *


*1.取数: Excel 上传数据并对数据bom 批量更改BOM组件
*2.输出: *


  • MODIFICATIONS (latest entry at the top) *
  • ------------------------------------------------------------------- *
  • REL DATE NAME (COMPANY) DESCRIPTION TASK-NO *
  • — ---- ---- --------- ----------- ------- *

*report zppr017b.

data csap_mbom type csap_mbom.

data t_stpo type standard table of stpo_api02 with header line.

data: begin of g_matnr occurs 0,
matnr like mara-matnr,
end of g_matnr.

data: filename type string.

  • 对应Excel导入文件的结构
    data: begin of gt_data occurs 0,
    matnr like mara-matnr,
    qty like stpo-menge,
    unit like stpo-meins,
    comp like mara-matnr,
    comp_scrap like stpo-ausch,
    item_no like stpo-posnr,
    end of gt_data.

data it_comp_data like standard table of gt_data with header line.
data wa_gt_data like gt_data.

&---------------------------------------------------------------------
*& 选择屏幕
&---------------------------------------------------------------------
selection-screen begin of block block1 with frame title text-001 . "‘请指定选择条件’.

"BOM 选择条件
parameters p_plant like csap_mbom-werks.
parameters p_usage like csap_mbom-stlan.
parameters p_alt like csap_mbom-stlal.
parameters p_datuv like csap_mbom-datuv .

selection-screen end of block block1.

selection-screen skip.

selection-screen begin of block block2 with frame title text-002. " ‘请指定本地EXCEL文件’
parameters: p_name like rlgrap-filename obligatory.
selection-screen end of block block2.

selection-screen skip.

selection-screen begin of block block3 with frame title text-003 . " ‘说明’.
selection-screen comment /2(79) text-004.
selection-screen comment /2(79) text-005.
selection-screen end of block block3.

initialization. " 初始化选择屏上的变量

  • 读取文件
    at selection-screen on value-request for p_name.
    call function ‘WS_FILENAME_GET’
    exporting
    def_path = ‘C:’
    mask = ‘,DAT(.DATA),.DAT.’
    "MASK = ‘,Excel文件
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值