SAP Process Order Idoc Outound – SAP IDOC LOIPRO (Sample ABAP)

SAP Process Order Idoc Outound: Sample ABAP is the last part of LOIPRO IDoc.

It will covers a sample ABAP code how to generate LOIPRO IDoc including preparing Data and calling the CLOI* BAPI to create a LOIPRO Idoc.

SAP Process Order Idoc Outound: Trigger LOIPRO IDoc when Save

Check more detail on How To trigger IDOC LOIPRO when PO Changed/Created.

The BADI to be implemented is WORKORDER_UPDATE and the method is AT_SAVE

SAP Process Order Idoc Outound: Prepare Data

Before calling the standard function CLOI_MASTERIDOC_CREATE_LOIPRO to create the LOIPRO01 IDoc for SAP Process Order Master, some structure must be filled.

Get here How to Get SAP Process Order Status

Here a sample ABAP code to fill the ORDER_DATA TYPE CLOI_AFKO_TAB

Here an other interesting SCN article Creation of production order IDOCs to a given selection

SAP Process Order Idoc Outound: Create LOIPRO IDOC

Once the table ORDER_DATA is populated, the CLOI_MASTERIDOC_CREATE_LOIPRO can be called to generate the SAP Work Order Idoc ( LOIPRO01).

You may also like:

Check also this article on Automation of LOIPRO outbound IDOCS on