cancel
Showing results for 
Search instead for 
Did you mean: 

how to set up more fields in swc_container_to_persistent wi_container

Former Member
0 Kudos

In my workflow I have to pass two values other than object key for (bus 2032) which I need to display in the workflow. new new values I have to add is

vamont and vtext which I created in the workflow container. I want to know how can I pass these values into the workflow.

Here is the coding which I gave to pass the value for the sales order. what else I have to add for the other two values.

vamount is the name and value is 10.00

vtext is the name value is 'Created'.

swc_create_object object 'BUS2032' objkey.

swc_set_element wi_container 'SalesOrder' object.

swc_container_to_persistent wi_container.

Accepted Solutions (1)

Accepted Solutions (1)

former_member598013
Active Contributor
0 Kudos

Hi,

For passing this type of value what you need to do is to

In BOR: first create an event which contains two parameters (vamont and vtext ) and check the check box while creating the parameter

In Workflow: then declare it in the workflow with the same data type .

Now then triggger the event explictly and bind corresponding to the event link the event with the workflow

and bind the parameters.

Then you would see when you execute your workflow container element will get the detailed information

&******************* Reward Point if helpful************************&

Former Member
0 Kudos

I am triggering the workflow using the program

swc_create_object object 'BUS2032' objkey.

swc_set_element wi_container 'SalesOrder' object.

swc_container_to_persistent wi_container.

  • start the workflow via the function API*

CALL FUNCTION 'SWW_WI_START_SIMPLE'

EXPORTING

task = task

called_in_background = 'X'

IMPORTING

wi_id = wi_id

TABLES

agents = agents

wi_container = wi_container

EXCEPTIONS

id_not_created = 1

read_failed = 2

immediate_start_not_possible = 3

execution_failed = 4

invalid_status = 5

OTHERS = 6.

martin_nooteboom
Active Contributor
0 Kudos

You must add your fields to the container just like you added the object. Use macro SWC_SET_ELEMENT.

Regards,

Martin

Former Member
0 Kudos

I am not able to get the values in the workflow

This is what I did in the program

swc_create_object object 'BUS2032' objkey.

swc_set_element wi_container 'SalesOrder' object.

swc_set_element wi_container 'Vtext' 'test02'.

swc_container_to_persistent wi_container.

is it correct?

Sales order number is comming in the workflow but Vtext which I created in continer is not comming.

Former Member
0 Kudos

Thanks for your help. it is working now. some how it was not activated.

Answers (0)