發表文章

目前顯示的是 2016的文章

[ABAP] Copy ALV Layouts between Programs

Solution 1. Try This Program....  直接作程式間的COPY Report copy_layout. data : lt_ltdx like ltdx occurs 0 with header line. data : lt_ltdxt like ltdxt occurs 0 with header line. parameters report like ltdx-report obligatory. parameters report2 like ltdx-report obligatory. "copy layout of report to report2. start-of-selection.   select * into table lt_ltdx from ltdx                 where report = report.   select * into table lt_ltdxt from ltdxt                 where report = report.   loop at lt_ltdx.     lt_ltdx-report = report2.     modify ltdx from lt_ltdx..   endloop.   loop at lt_ltdxt.     lt_ltdxt-report = report2.     modify ltdxt from lt_ltdxt..   endloop.   message 'Copy Complete.' type 'I'. Solution 2. 直接使用來源程式的Layout Instead of sy-repid, G_VARIANT-REPORT = SY-REPID. SY-REPID 為複製Layout的來源程式...

[SAP] NOTES匯入使用

1. service.sap.com/            → 下載notes的txt檔 2. TCODE: SNOTE 做txt上傳

[PP] 判斷不同BOM修改, 將BOM核發狀態改為unrelease

BAdI: BOM_UPDATE Method: CHANGE_AT_SAVE [CODE] METHOD IF_EX_BOM_UPDATE~CHANGE_AT_SAVE.   CHECK SY-TCODE EQ 'CS02'.   DATA: WA_STPO TYPE STPO,               L_MATNR TYPE MAST-MATNR,               L_WERKS TYPE MAST-WERKS,               L_STLNR TYPE MAST-STLNR,               L_STLAL TYPE MAST-STLAL,               TB_STPO TYPE STANDARD TABLE OF STPO,               L_RELEASE(1) TYPE C,               WA_STKO TYPE STKO,               WA_MAST TYPE MAST,               WA_STPO2 TYPE STPO.   CLEAR L_RELEASE.   LOOP AT DELTA_MASTB INTO WA_MAST.     MOVE: WA_MAST-MATNR TO L_MATNR.     MOVE: WA_MAST-WERKS TO L_WERKS.   ...