ewx hat geschrieben: ↑11.11.2020 11:51
Danke, habe ich probiert, gleiche ergebnis:
**Kopf Ändern
CALL FUNCTION 'MD_PLDORD_CHANGE_ALL_BAPI'
EXPORTING
* ECM61O =
eplnum = '0000011111'
* ECM61S =
eplaf = ls_headerdata
EBAPIPLAF_I2X = ls_headerdatax
* IMPORTING
* IPLAF =
* ICM61O =
* ICM61T =
* ISCHED =
* IBOMCH =
* TABLES
* CM61FX =
* EMDPM =
* EXCEPTIONS
* LOCKED = 1
* LOCKING_ERROR = 2
* CHANGE_ITEM_NOT_FOUND = 3
* NO_CHANGES_IDENTIFIED = 4
* OTHERS = 5
.
IF sy-subrc <> 0.
* Implement suitable error handling here
ELSE.
COMMIT WORK AND WAIT.
ENDIF.
SET UPDATE TASK LOCAL.
* change material component in internal tables
CALL FUNCTION 'MD_PLDORD_CHANGE_COMP_ITEMS'
EXPORTING
EPLNUM = I_PLNUM
ECM61O = ls_lcm61o
TABLES
EMDPM = lt_COMPONENTS_DATA "lt_MDPMX
EXCEPTIONS
LOCKED = 1
LOCKING_ERROR = 2
CHANGE_ITEM_NOT_FOUND = 3
NO_CHANGES_IDENTIFIED = 4
OTHERS = 5.
IF SY-SUBRC <> 0.
* SUCC_CODE = C_SUCC_CODE-OK.
ELSE.
COMMIT WORK AND WAIT.
ENDIF.