Addressing Selected Agent by Name When Using a Rule

Mike Pokraka wug at workflowconnections.com
Mon Feb 27 05:04:59 EST 2012


Hi Ali,

You couls move the code from your FM into a method and return a user object.
A background step would then call ZCL_PURCH_REQ->GET_APPROVER and the
approval step goes to AGENT->ID and addresses AGENT->NAME.

Regards,
Mike

On Thu, February 23, 2012 9:34 pm, Ali Husain wrote:
>
>
> Hello WF experts,
> I have a rule where i'm executing a function module to retrieve a certain
> agent. When sending him the decision work item i want to be able to
> address him by his name. Is there a way to get the selected agent name
> automatically so that i can use it in the work item description? I thought
> of retrieving his name inside of the rule itself and then setting the
> value in the container and back to the workflow but i was not getting any
> value in the workflow container element. I'm not even sure if that would
> work: passing the value back from the rule to the wf container then to the
> task container so that i can address the agent by his name in the
> description. I was able to get data from the rule container but not set
> any values to it using the below code:
>
>
>
>
>
>
>
>
>   DATA: lv_dummy type char30 value 'Hello'.
>   swc_set_element ac_container 'v_dummy' lv_dummy.
>
> I also tried binding the _rule_result but it only contains the user id of
> the selected agent and not his name. I could retrieve the name in a
> previous step but I was wondering if there's a better way.
> Appreciate your help.Thanks, Ali
> _______________________________________________
> SAP-WUG mailing list
> SAP-WUG at mit.edu
> http://mailman.mit.edu/mailman/listinfo/sap-wug
>




More information about the SAP-WUG mailing list