Skip to Content
avatar image
Former Member

Passing Data from BTE 1025 in Custom Workflow

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

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Oct 29, 2015 at 07:07 AM

    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

    ,

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      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

  • avatar image
    Former Member
    Oct 29, 2015 at 07:13 AM

    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

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      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

  • Oct 29, 2015 at 12:14 PM

    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

    Add comment
    10|10000 characters needed characters exceeded