cancel
Showing results for 
Search instead for 
Did you mean: 

Passing Data from BTE 1025 in Custom Workflow

Former Member
0 Kudos

Hi,

I am relatively new, kindly guide me on this.

I have done a lot of research and have been confused.

Heres what I need to do.

Trigger a custom workflow from BTE.

The workflow needs some data from the BTE like Doc Number, Posting Date,etc that needs to be sent for approval via workflow.

What I have did so far

I activated BTE 1025 and and called FM SAP_WAPI_START_WORKFLOW

I then created a WF and gave its ID in the above FM.

My Issue:

I do not understand how to use the data sent via input_container in the workflow I created.

Because the approval mail needs to have details about Doc Number, Posting Date,etc.

Everywhere on forum how to send the data is written, but I did not find retrieval and usage.



--

Regards

SAurabha J

Accepted Solutions (0)

Answers (3)

Answers (3)

StephaneBailleu
Active Contributor
0 Kudos

Hi,

Have you created the container element in your workflow as well ?

You have then from your event in the worflow header to make the binding between the event parameters and the workfow import container element.

When this is done the event parameters are then available in your workflow.

and you can use transfer the workflow container element in the different step of your workflow by using the binding from workflow container to task container,

Once the task container is filled you can use the different element in your workitem text.

Containers and binding are the very basics tool that help to communicate data between the different step of your workflow.

I hope this will clarify your issue.

Stephane

Former Member
0 Kudos

Hi Stephane,

I am aware I need to do the same. But I am not sure how do I call that data.

Would it be that I will have to create a BOR Object ?

--

Regards

SAurabha J

StephaneBailleu
Active Contributor
0 Kudos

Well, first I don't know if you are aware that you do have a transaction in order to make event for workflow SWU_EWBTE based on BTE.

Then on your workflow yes you should certainly use an FI object like BSEG ?

And you could certainly instanciate it ?

Cheers

Stephane

former_member185167
Active Contributor
0 Kudos

"I do not understand how to use the data sent via input_container in the workflow I created."


You use it just like any other data in the workflow: just bind it to whichever step you want to use it in.

Former Member
0 Kudos

Hi Rick,

Sorry for being ignorant.

Can you explain me the process in detail or with screenshots or provide a link with detailed explanation ?

--

Regards

Saurabha J

former_member185167
Active Contributor
0 Kudos

Hello,

If you don't know how to do bindings then every step of the way will be a new question.

I can only recommend:

http://www.workflowbook.com

regards

Rick

0 Kudos

Hi Saurabha,

Refer to below link for Binding Details in a Workflow.

It may help.

http://wiki.scn.sap.com/wiki/display/ABAP/Binding+Definition+in+Workflow

Thanks and Regards,

Vikram

Former Member
0 Kudos

Hi Vikaram,

I am still not sure, how can I access the data sent.

The link you shared have some insights though.

--

Regards

SAurabha J

anjan_paul
Active Contributor
0 Kudos

HI,

   First you create container  element ELE1 in the workflow . Then pass the the exact name and

data: s_evt TYPE swr_cont,

t_evt LIKE TABLE OF  s_evt .

s_evt-element = 'ELE1'.

s_evt-value =  'Value'


append  s_evt TO  t_evt.

And pass the t_evt to FM as input_container

,

Former Member
0 Kudos

Hi Anjan,

I already did that.

Check code below:

data: lt_container type swr_cont occurs 0 with header line,
         ls_container type swr_cont.

   ls_container-element = 'Document Number'.
   ls_container-value = I_BKDF-BELNR.
   append ls_container to lt_container.
   clear ls_container.

   ls_container-element = 'Posting Date'.
   ls_container-value = BKPF-BUDAT.
   append ls_container to lt_container.
   clear ls_container.


call function 'SAP_WAPI_START_WORKFLOW'
     exporting
       task            = 'WS90000008'
       language        = sy-langu
       do_commit       = 'X'
       user            = sy-uname
     tables
       input_container = lt_container.

endfunction



I want to know when I open WS90000008 via SWDD where/how can I access the above values.


--

Regards

SAurabha J