cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with business object using BAPI for sales order

Former Member
0 Kudos

Hi,

My requirement is to send work item for approval/rejection for sales order discount condition based on sales organization.

I have created custom business object ZSEBUS2032 and delegate it to BUS2032.


My workflow is triggering fine and work item is sent to SAP Inbox. Once Approve/Reject action is performed in the work item then the same condition value has to get updated in sales order. so I am using BAPI_SALESORDER_CHANGE for the same.


The value is updated correctly, but here the problem is when the BAPI is getting triggered, again standard business object BUS2032 is triggered and again work item is updated in the Inbox.


Can anyone please suggest to control business object getting triggered when using BAPI.

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

http://scn.sap.com/thread/3383394

Hi Kusuma,

Kindly define Check FMs in SWE2 to check whether any active instance of the workflow exists for the same Sales Order. If an active instance for the Custom Workflow Template exists for the same key(Sales Order#), then raise the exception in the check FM.

The exception will ensure that another instance of the workflow does not trigger for the same Sales order.

Kindly refer to the above link for further details on Check FM concept.

Thanks and Regards,

Vikram

Former Member
0 Kudos

Thank you..it works

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

If I understand You correctly Your WF is triggered again after You change Sales Order using BAPI right? Or?

br,

artur