‎2007 Jan 30 6:38 AM
Hi i am using a BAPI : BAPI_SALESORDER_CHANGE.
My requirement is:
i have a report which displays sales order, material no and rejection code in a row.
Now if i select a row and click on the user button (which i created it) the rejection should be empty ( get modified as blank in the database tables ) that is the material for that sales order should get unrejected.
Could anyone pls help me how to achieve the same thru this BAPI.
the internal table from which i display this report is itab.
thanks
John
‎2007 Jan 30 6:43 AM
Hi,
Change in the status of an item of a sales order implies that the sales order is changed. Hence Use the BAPI 'BAPI_SALESORDER_CHANGE', to change the Sales Order.
In the items table structure 'ORDER_ITEM_IN'(Structure 'BAPISDITM')mark the field 'REASON_REJ' with the reason for rejection passed to the VA02 BDC.
Point to note here is if a sales order is to be changed, then the structure 'ORDER_ITEM_INX'(Structure 'BAPISDITM') should also be populated (this is mandatory). Mark the field 'REASON_REJ' of this structure with 'X'(this means that the reason for rejection is to be updated).
The mandatory field to be populated in both tables structures 'ORDER_ITEM_IN' and 'ORDER_ITEM_INX' is 'ITM_NUMBER', which is the item number.
This would work.... Dont forget my points ;-).
Regards
Sudheer