AnsweredAssumed Answered

Script Task ->(to) Multiple E-mails

Question asked by ramonck on Aug 4, 2014
Latest reply on Aug 5, 2014 by ramonck
Hey guys,

First thanks for making this tool, it seems hot.

I'm doing my first proof of concept and I observed that the best way to do my logic would be through a "Script Task"

So my initial flow now is:
Start Task -> E-mail Task (Saying hey I started the process, let's rumble) -> Script Task (Groovy going to web service and fetching a list of users with e-mails)

Now I want to build another leg which is Send out e-mails to these users.

So I'm retrieving from the result from the webservice as the following in the Groovy Script: Users[] which will provide me the list users+e-mails from the web service. From what I read in teh forum I would probaly expose it as execution.setVariable("userEmail", $[User.email])
but now what? :)
Now I want to make use of this list and send out e-mails through a next step task which would be the Messaging Task how would I encapsulate to I can do it from te results I obtained in the Script Task? I want it so I can send out as many e-mails as I have User objects in my list, it would be the same e-mail body and header, I just want to change a link I will put in the body, which I will reference as ${linkAttachment}

Best Regards,

Outcomes