Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Updating workflow container element

Former Member
0 Likes
998

Hi,

I have a workflow and I want to update the initial value of a container element through a report. Can anyone tell me what classes and methods to be used?

I tried the following way but the container element's value is not updated.

data : container type REF TO CL_SWF_CNT_CONTAINER,

ok_container type XFELD,

value TYPE asr_form_scenario.

CREATE OBJECT container.

CALL METHOD container->if_swf_cnt_container~set_guid

EXPORTING

guid_32 = 'WS95000614'

receiving

ok = ok_container

.

if ok_container = 'X'.

CALL METHOD container->if_swf_cnt_element_access_1~element_set_value

EXPORTING

name = 'Form_SHI2'

  • qname =

value = 'SHI1'

  • unit =

  • IMPORTING

  • exception_return =

.

endif.

Thanks & Regards,

Reena

3 REPLIES 3
Read only

former_member150733
Contributor
0 Likes
719

Can you please refer the sdn thread

Read only

Former Member
0 Likes
719

hi

good

go through these links, i hope these ll help you to solve your problem.

/people/jocelyn.dart/blog/2006/07/27/raising-abap-oo-events-for-workflow

http://www.erpgenie.com/workflow/tips.htm

thanks

mrutyun^

Read only

Former Member
0 Likes
719

Hi Reena,

I had a scenario like i need to trigger a Workflow through a Report Program. If you too are working in similar kind of scenario then you can do like this,

Declare the following datas.

TYPES: BEGIN OF gty_zbus100106_key,

idnrk LIKE stpo-idnrk,

werks LIKE marc-werks,

END OF gty_zbus100106_key.

DATA: gv_objectkey LIKE sweinstcou-objkey,

gwa_zbus100106_key TYPE gty_zbus100106_key.

loop at the internal table.

Move key values to gwa_zbus100106_key.

move gwa_zbus100106_key to gv_objectkey.

Use Function module to trigger the Workflow.

CALL FUNCTION 'SAP_WAPI_CREATE_EVENT'

EXPORTING

object_type = gc_objecttype " 'ZBUS100106'

object_key = gv_objectkey " Object Key (Material No+Plant)

event = gc_event " 'ZMMEXT'

commit_work = 'X'

IMPORTING

return_code = lv_ret_code

event_id = lv_event_id.

endloop.

This will work. But let me know if this your scenario so if anyother thing then i could try to find any class or methods to solve this issue.

Thanks

Prashanth