cancel
Showing results for 
Search instead for 
Did you mean: 

Object key issue in Workflow triggering using Class

Former Member
0 Kudos

Hi All,

I am not getting object key which i passed ,when i triggered workflow using Class event.

I have triggered workflow using class event

CALL METHOD cl_swf_evt_event=>get_instance

EXPORTING im_objcateg = 'CL'

im_objtype = 'Class name'

im_event = 'Event name'

im_objkey = <Eg : ABCD123>

im_event_container = lo_event_container

RECEIVING re_event = lo_event_ref.

CALL METHOD lo_event_ref->raise.

In run time all custom workflows object type stored as this class name "CL_SWF_UTL_EVT_IDENTIFIER" instead of passing different class name in above code.

Object key stored as Instance ID <different number>in table SWW_WI2OBJ. i am not able to get object key which i have passed <Eg : ABCD123> any places and tables.

how to convert or link between Instance ID to object key which i passed ?

i want to filter particular workitem using below FM "SAP_WAPI_WORKITEMS_TO_OBJECT" object key as <Eg : ABCD123>

Please help me the same

Regards,

Venkat

Accepted Solutions (0)

Answers (2)

Answers (2)

jens_we
Explorer

Hi Venkat,

you have probably forgotten to implement the workflow interface IF_WORKFLOW. Important are the LPOR methods to save your ZCLASS and your IDENTIFIER to the database. After this implementation you should be able to see your entries in table SWW_WI2OBJ.

Regards,

Jens

pokrakam
Active Contributor
0 Kudos

Jens has given you some good advice for the class implementation.

Also, please use the SAP_WAPI functions unless you have a specific reason to do otherwise. For class and BOR events, it's FM SAP_WAPI_CREATE_EVENT_EXTENDED.

Another thing: just look in the WF container to see if your object instance works, rather than tables or using function modules. Much easier.