SAP Function SWW_WI_CREATE_VIA_EVENT - Create Work Item as Result of Event

Parameter Reference Type Length Default Optional Text
EVENT SWETYPECOU-EVENT C 32 Name of Event
EXCEPTIONS_ALLOWED SWEFLAGS-EXC_OK C 1 SPACE X Indicator Showing Whether FM Can Raise Exceptions
OBJKEY SWEINSTCOU-OBJKEY C 70 Key of Triggering Object
OBJTYPE SWETYPECOU-OBJTYPE C 10 Type of Triggering Object
RECTYPE SWETYPECOU-RECTYPE C 14 Type of Event Receiver, Here: Task ID

Parameter Reference Type Length Text
REC_ID SWELOG-RECID C 90 Key of Receiving Object

Parameter Reference Length Optional Text
EVENT_CONTAINER SWCONT 297 Event Container

Exception Text
CREATE_FAILED Create Work Item Failed
READ_FAILED Read Definition for Task Failed

Functionality
This function module creates a work item from an event. The type isderived from the type of the task. The underlying task must be passedwith the parameter RECTYPE.
The binding from the event container to the required work itemcontainer is completed in the function module. This binding must havebeen defined for the task, and is the only way of providing the workitem container with data. All other parameters required to create thework item can only have the default values declared for the work itemor task (for example, rules for agents, priority, callback modules,deadline handling).
If no binding of this kind is defined, the relevant work item is notcreated. Error handing can be defined on the tab page Basic data inevent queue adminstration.
INCLUDE WF_FB_EVENT_OBJECTKEY OBJECT DOKU ID TX
INCLUDE WF_FB_EVENT_OBJECT OBJECT DOKU ID TX

Description
The ID of a task or workfow must be passed asreceiver type.

Value range
Valid ID of task or workflow in the form (two-character code) +(eight-digit number).
INCLUDE WF_FB_EVENT_EVENTCONTAINER OBJECT DOKU ID TX

913330tRFC LUWs are not created