We are triggering the event for BUS2032 WF using FM SWE_EVENT_CREATE.
For Sales Order with large number of line items, say our logic determined that for three material families, three WF event should be triggered for some approval.
The event gets triggered successfully for the first family, fails for the second and again triggers successfully for the third family.
Error Message: Source (expression '&_EVT_OBJECT.SALESDOCUMENT&') of binding assignment is not available
Strangely, this problem is only for Sales Order with large number of line items. For Sales Order with less number of line item, workflow events are getting triggered as expected.
We are calling the below FM in Loop. Any one faced this similar issue??
CALL FUNCTION 'SWE_EVENT_CREATE'
EXPORTING
objtype = 'BUS2032'
objkey = v_object_key
event = 'OMPEVENT'
IMPORTING
event_id = v_eventid
receiver_count = v_eventid1
TABLES
event_container = lt_wf_cont
EXCEPTIONS
objtype_not_found = 1
OTHERS = 2 .

