Task container to workflow container binding

Hi all,
I have a requirement to send mail to department responsible of a quality notification as soon as it is created from defects recording.
I am using sendmail step for this but since it doesnt have agent determination using rule, I am forced to create a background step which captures the value of department responsible (IHPA-PARNR) and passes on to a element in workflow container. The idea was I could later use the value of this container element in my send mail step which follows.
For this, I have defined a background step in my workflow template. The method in the standard task of this step refers to a function module.
The function module takes quality notification number as input (QMEL-QMNUM) and outputs the partner number (data type IHPA-PARNR).
I want to capture this partner number into my workflow at runtime. For this I defined a workflow container element refering to IHPA-PARNR so that it can bind to the export parameter of the task, which gets the value from method.
when I test my function module it works fine. BUt when I try to bind the task to my workflow, the binding between the elements refering to IHPA-PARNR gives error this error message:
" incompatible data type reference"
whereas the data type reference is same for both container elements.
Please help.
Thanks
kiran

Hi Ramki,
This is the binding from workflow to task container.
X                 => &EXPRESS&
G                 => &TYPEID&
&DEPTRESPONSIBLE& => &ADDRESSSTRINGS&
Here the DEPTRESPONSIBLE is the WF container element which gets the value of department (basically a org structure IHPA-PARNR) via a background task in the previous step.
And in the recepients list, I have given
recepient type : organizational object
expression     : &DEPTRESPONSIBLE&
I think this is where the problem is. Because when I give workflow initiator as recepient, it works fine. But when I give the department responsible as expression as shown above it errors out.
It also works fine when I hardcode the value of department responsible in the recepients list (say 50001930)and give recepient type as Organizational object.
So the problem is it is not taking the value stored in the container element &DEPTRESPONSIBLE& as the recepient.
Any ideas.
Thanks a million.
kiran

Similar Messages

  • Workflow basics...Container / Rule / Workflow adn Binding

    Hello friends,
    I want to know the basics of Container Element and the process flow between workflow , Task and rule using Container element.
    also tell me about the binding of each.
    I would like to know the basics of each.
    can anyone provide me some refrerenc material / link / documentation?

    Hi,
    Container is nothing but a variable which hold data . Assume that there is a binding between workflow  to Task . Here you can pass value from Workflow to Task via containers. You can create container seperately on both sides and exchange datas during runtime. Container also hold values like to store them in a table which is called a Multiline container.
    Binding is basically to connect one process with other. Ex. Binding between task and Method
    Rule is used to sollect the agent to run the particular task . The standard rule will refer the Org structure to collect the agents. the custom rule can be used to collect them from a custom table.
    Reward points if useful!
    Richard A

  • How to create a container element in workflow container

    Hi,
    I am learning WF by a Tutorial. In which absence of notification was considered as example. As per tutorial, I created two task for creating a Notification and checking a absence
    In the next step it ask to create a container element(approver) to workflow container. How i can create the same.
    Also, please clarify me on the binding between task container and workflow container....with this example
    Thanks
    Suresh

    Hi,
    On the workflow builder LEFT side below the navigation area u can see this <Double-Click to Create>.
    Double click and create the container.
    During binding it looks as follows.
    Workflow  -
    >   Task
    Workflow <----
    Task
    What happen here is from workflow the data passed to task and it is used for processing, after that it returned back to the workflow. Now u can create the container on bothside and bind the data. ie Variables.
    Creating container u can refer : http://www.****************
    Reward for useful answer.
    Richard A

  • Workflow container elements as attachment in an activity

    Hi @ all
    Iu2019m searching for a resolution to display a multiple attachment in an activity of my workflow.
    The scenario is as follows:
    An Activity should display the image, a generated attachment (from the User decision before) & the workflow conatainer elemnts of the included task. So far so good. The image and the attachment are displayed in the next activity, but how can I display the container elements?
    I need them because the user dynpro-inputs are stored in it. I generate the elements in my task and bind them from the workflow container. And now? What is the next step to get them in an attachment?
    THX
    REGRADS
    Phil
    Edited by: Philipp Höfer on May 18, 2010 2:09 PM

    Hi Karri,
    thanks again.
    if i understand you correctly, i'm going to my Step Task ->(n my case "Display Image"). After that to the tab -> Description and push the button "change text" to insert a new text. But how can i insert my container elemt values.
    There is a button "Program Symbol" but their is no entry. The Binding of the task and the workflow container is correctly.
    What i am doing wrong?
    THX
    Regrads
    Phil
    Edited by: Philipp Höfer on May 19, 2010 12:12 PM

  • How to create workflow container element from workflow builder?

    How to create workflow container element from workflow builder?

    in workflow
    three are five container, for each container we have define according to requirement of that particular container.
    1. event container
    2. workflow container
    3. task container
    4. method container
    5. rule container
    1. event container
    in evernt contianer we have to create elements in BOR where we create event in parameters
    2. workflow container
    in workflow container we have to create elements in workflow builder itself. in left side of the screen we see <double click to create element>
    3. task container
    in task container we have to create in task itself it has a tab called container elements
    4. method container
    in method container we have to create in BOR. it is created in parameter of that BOR.
    5. rule container
    in rule container we have to create in PFAC transaction

  • Can any body tell me about event container in workflows

    hi Experts,
                      could you please tell me some details about event container concept. is there a way to see event container in SWO1 transaction. how can we create event container when we create new events.

    Hi Praveen,
    Event container is the container which stores the values of the BO attaribures which get assigned to that instance of the BO.
    If you go to SWO1 transaction and check the BO for which the event is triggered, you would see all the possible attributes than can be assigned.
    To pass the values of the BO event container to the workflow, you need to maintain the necessary binding between the BO event container and the workflow container. This can be done in the 'Basic Data', Start Events tab. If you click on automatic binding, the system would prompt for a default binding. You could opt to use that or create your own binding. Make sure that the datatypes match.
    After mapping the event container to workflow container, you can check in the workflow log for the values passed to the workflow container. If you like to directly check the values stored in the event container, go to SWO1 and simulate an instance of the BO. You can then check the values there.
    Hope this helps!
    Regards,
    Saumya

  • Custom Rule - Problem in passin values From Rule Container to WF Container?

    Hi Guys,
    I am having hard time passing values back from my custom rule. I have created a custom rule to determine the agents in PFAC which takes in the Person number as import element of container. It determines the Manager as agent and I am passing Managers Person Number back to workflow. If he dont approve the Request then it will be passed to his boss. In this case I will pass this imported Mangers Person number back to rule so that his boss will be determined as agent. I  have created ZRULE function module. I am passing value back from Rule container to Workflow Container using following code.
    swc_set_element ac_container 'SUPERPERNR'  lf_super_pernr.
    I have created a element SUPERPERNR on rule container and workflow container as well .The problem is in the Rule container I am not able to create SUPERPERNR as export parameter. The tick mark is grayed out and there is no option for setting it as export.
    My question is do I have create a Export element on Rule container or Not? If i just write the code
    ( swc_set_element ac_container 'SUPERPERNR'  lf_super_pernr ) will it set the value in WF container? In my case it is not setting. I have to bind the values from rule container to WF container and if My rule container element is not allowing me to click the tick mark as export how can i pass value of of rule container back to WF Container?
    Please help me guys.
    Thanks,
    Manish.

    Hi Manish,
         Same scenario I have developed in my system. This all steps I did in my system.
    1) Created a Z function module which takes import parameter (Parameter name = 'EMP') in the
        format 'US100123'.
    2) This in turn fetches back the supevisor or boss as an export parameter (Parameter name = 'BOSS') in
         the format 'US100245'.
    3) This function module is attached to a BUS object(SWO1).
    4) While attaching this function module to BUS object you need not do any manual coding it is done
        automatically.
    5) Implement, release and generate this BUS object.
    6) Create a new variable in your workflow (Parameter name = 'ZSUPERVISOR') for storing the value
        which is returned by the Z method.
    7) Create a new task.
    8) Put in your BUS object name, then your Z method name, select background processing checkbox.
    9) Press save, it will ask for transfer of missing elements, select yes.
    10) Then you will see a green button below your Z method name click on it.
    11) Top portion contains your Z method variables, below to it you have the import parameter window in
          this window you should have &EMP& -> &EMP&., below to import parameter window you have
          export parameter window in this window you should have &BOSS& <- &BOSS&. (This is method
          binding).
    12) Now click on enter button then click on back button it will generate the task binding automatically
         just press yes.
    13) Now click on binding exist button.
    14) Here you have the Workflow container variables as well as the system container variables.
    15) In the import parameter window left portion is for your workflow variables and right portion is for your 
          method variables. In my case i had sent workflow initiator and fetched his supervisor. The Import
          parameter binding was &WF_INTIATOR& -> &EMP&. and the export parameter binding part was
          &ZSUPERVISOR& <- &BOSS&.
    16) Save the task and run the workflow.
    Regards.
    Vaibhav Patil.

  • Access the adobe form data in the workflow container for further processin

    HI,
    I am using HCM processes and Forms. I need to access the form data in the workflow container once the workflow kicks off.
    I need to access these data as would need it for further processing in the workflow.
    I know that TS17900110 allows to import form conatiner to
    -> WF Container in the field name and value pair. But I need to access a lot more fields than what is in the task. Is there a standard task which allow to retrieve all the fields in the form in one task or do I need to develope a custom class to do that. If so could you please provide some clue as in how to code this specific requirement as i am somewhat new to OO ABAP.
    Thanks...

    hi,
    in the livecycle designer under libary tab u have webdynpro tab--->choose submit to sap button and place it in the adobe form ur designing. u can use this button to trigger the code that u have written in webdynpro java.
    for eg if u have
    a value node details
    and under that two value attr fname,lname
    import the model (Insertdata---it has two import param fname and lname)u need for updating the data to r3 system.
    in the ctrller have a method submit.Here write the code to insert fname and lname into the db.
    IPrivateMyForm.IDetailsElement elem = wdContext.nodeDetails().currentDetailsElement();
    Insertdata_Input input = new Insertdata_Input();
    wdContext.nodeInsertdata_Input().bind(input);
    input.setFname(elem.getFname());
    input.setLname(elem.getLname());
    try
    wdContext.currentInsertdata_InputElement().modelObject().execute();
    wdContext.nodeOutput().invalidate();
    catch (Exception ex)
    { ex.printStackTrace();}
    ul bind details to the datasource.
    when u edit ur interactive ui element these attr(fname and lname) vl be visible under dataview tab u can drag and drop them to the form
    now add submit to sap button in ur form.
    this button correspond to the onactionSubmit dat u have written in the ctrller.
    so wen u click this the data vl be inserted
    Regards
    Jay

  • Over Time Workflow Container elements not updated

    Hi,
    I am using Standard Task TS20000459 for approval of Overtime entered for an employee in CAT2 transaction.
    Work item is getting generated to his manager's inbox.
    Issue is, subject of the work item should have employee number and Employe name. Standard Task contains Container elements &TS_PERNR& and &TS_ENAME& which is not getting filled with any values.
    Can any one suggest me how to get the same?
    Regards,
    Saravana Perumal

    Hi Shanti
    I faced the same problem...And i resolved that problem by binding...
    Create the container element for PERNR and ENAME in the standard task ts20000459 as well as in workflow container.Then bind those container values.
    Before bind the workflow and task container, you have to bind the workflow container with the event container.
    Regards,
    Hemalatha.

  • Workflow issue - Main workflow container elements are not updated.

    Hi All
    We have implemented N-step badi for approval process and for this we have activated one workflow which contains subworkflow .
    During approval process , only the subworkflow container elements( approver list and last approver) getting updated with status and time.But main workflow container elements is not updating with these details.
    Binding between main workflow and subworkflow is perfect. But reverse binding ( from subworkflow -> main workflow ) will take place once subworkflow is completely finished. But here we will require / need to pass some information from sub workkflow to main workflow when still subworlflow in process( before completed itself).
    Please let me know is there any process / steps is required to pass values between subworkflow to main workflow ( binding is perfect).
    Please let me the way how I can update the main workflow container from  subworkflow container or from any step in sub workflow .
    In subworkflow . we have loop of  approvers and it will send workitems to approvers one by one.
    Here i need to update Main workflow with the information like last approver and approver list with status and approved time.
    So please suggest how Can I update main workflow container from subworkflow while subworkflow is still in process( subworkflow not yet completed).
    Kindly reply me ASAP.
    Thanks and Regards
    Madhukar .

    Yes I am setting SWC_SET_ELEMENT for my container values,the ones for which i have defined as EXPORT.
    And I have checked the task also...
    Everything has been checked properly..The binding is fine.
    Thanks & regards,
    Ravikiran Kallimath

  • Rule Result not returned back to Workflow container

    Hi ,
    We have a workflow where the approver for a Process is Manager of  any Orgunit .
    Now the manager is determined using a Rule with Category u201CFunction To be executedu201D .
    The Business requirement is so that If the immediate manager for any Orgunit is not maintained it will traverse through the entire Org structure unless the Manager is determined.  So the Level of the First approver could be of any value starting from 01.
    We also have Deadline  monitoring active .
    Incase the first approver  doesnu2019t act within 7 days  the Work item should go to the next level Manager ( second  approver ).
    The level of the second  approver depends on the level of the First approver .
    Example : If  the level of the First approver   is 3 then the level of the second approver  would be 4 or more.
                  : If  the level of the First approver   is 2 then the level of the second approver  would be 3 or more.
    Hence to achieve the Level dynamically we need to pass the Level of the first  approver  from the Rule to the Workflow  so that it can be used for determining  the next level manager in the next task.
    In the Function Module which determines the first approver  I have got the Value for the Level .
    I also have assigned that value to the Rule Container (_WI_RESULT , this is the only parameter which can be used for the Export )  using the Macro SWC_SET_ELEMENT  .
    I also have done the  binding from the Rule to the Workflow. But the value is not populated in the Workflow container .
    Could any one please help me  on solving this ??  Any other idea to achieve this is functionality is welcome too.
    Regards,
    Raka

    Hi  Arghadip,
    First of all thanks for the reply .
    We alreday have some logic  like this in place .
    But we want to imporve the system performance .
    We get the agent in one task from the Rule .
    Now again if we try to get the same agent in a method ,won't it be doing the same task twice.
    So we are trying to return the manager Counter value from the Rule container itself to the Workflow container so that it can be used to get the escalation manager.
    Regards,
    Raka

  • Creating Workflow Container Elements

    Hi,
                   I am looking to create two new workflow container elements of lenght 80char for 'WS92000027'  inorder to hold the required name to be outputted in the workflow . Could you please let me know setp by step procedure to achive this as am new to workflows .
    Thanks,
    Kumar.

    Hi,
    Create an element in the workflow container with the ABAP Dictionary data type "CHAR_80". Bind the variable accordingly from the task container or the event container and use it.
    Hope this will help.
    Thanks,
    Samson

  • Pass Work Order attachments to Workflow container

    Hi experts,
    I have a question concerning passing attachments from Work Order to Workflow(or Task) container.
    There are several files attached to Work Order in TCode IW32.
    The files are attached directly and are saved on SAP server. Not via URL.
    I have to send email in Workflow with these files attached to email, i.e. to pass them to workflow or task container.
    If I use BO SOFM I need to get the path where the files are saved on SAP server.
    How can I add these files as attachments to email?
    Thank you.
    Nina

    Hi,
    Add a step in the workflow to add the attachment befer sending mail step.
    Two thing you need to know.
    1. Workflow workitem id
    2. attachment name and location.
    Now first upload the attchment to workitem id through FM SAP_WAPI_ATTACHMENT_ADD.
    Then make the binding between the workflow container and mail step for &_ATTACH_OBJECTS&.
    after this attachment will be available in the mail.
    Thanks and regards,
    SNJY

  • Passing values from and to workflow container

    Hi Guys,
                 I am reading and writing back into the workflow container element from task container using FM.
    But its not writing back the values into workflow container.
    here is my code.
    swc_get_element container 'TripNumber' trip_no.   
    Fetch Personal No. from Trip No.                
      SELECT SINGLE pernr FROM ptrv_head INTO l_pernr  
        WHERE reinr = trip_no.                                                                               
    IF sy-subrc NE 0.                                 
      EXIT.                                            
    ENDIF.                                                                               
    Fetch Employee Name                             
    SELECT SINGLE ename FROM  pa0001 INTO l_ename      
           WHERE  pernr = l_pernr                      
           AND    endda  >= sy-datum                   
           AND    begda  <= sy-datum.                  
    Fetch Employee Email id                         
    select single usrid_long from pa0105 into l_email 
       where pernr = l_pernr                           
         and usrty = '0010'                            
         and endda  >= sy-datum                        
         AND begda  <= sy-datum.                       
    Set Personal No.                          
    swc_set_element container 'Pernr1' l_pernr. 
    Employee Name                             
    swc_set_element container 'Ename' l_ename.  
    Email ID                                  
    swc_set_element container 'Email' l_email   
    Am I missing anything here.
    Thanks

    Hi,
    I faced the same issue and i found that it is not sufficient to just have proper bindings and using macros with exact container names.
    You need to create IMPORT and EXPORT parameters for that METHOD with names matching with container element names. Once you do this, you see a GREEN binding icon right below the BO and Method name in the TASK. Click that icon and create binding between TASK and METHOD.
    This should resolve your problem.
    All - Please correct me if am wrong as i am new to the workflow.
    Thanks,
    SKJ

  • Attaching BO to Workflow container

    I have a Requirement: that I want to send mail with one object as attachment. When clicking on that attachment I should go to particular transaction.
    Things I have figured out till now: that I will create one BO and attach it to workflow container attachobject. then I will bind attachobject to _attachments in Send mail task container . So when Clicking the BO, display method of that BO will get called, and in that Display method redefinition , I will call the Transaciton.
    But how to attach the BO to attachobject. ...is there any fucntion module to do that.

    Hi,
    Do you want to send mail from inside the workflow definition, using the standard "mail" step?
    In that case, I think you should use either wiobject_id for the current business object processed by the workflow, and adhocobjects for any other business objects. I think attachobjects is for attaching text or binary files.
    Sandra

Maybe you are looking for