Looping the workflow

loop
uiautomation
activities
studio
for

#1

Hi Friends,

I am very new with UIpath, Can anyone teach me how can I make the same workflow to run 3 times without manually click run every time?


#2

Hi @pingggggg,

You can use While or Do While Activity for that. If you want to invoke workflow inside while loop try using Invoke Workflow File Activity.

While: https://studio.uipath.com/v2017.1/docs/the-while-activity

Do While: https://studio.uipath.com/v2017.1/docs/the-do-while-activity

How to use Invoke Workflow File Activity: https://www.uipath.com/kb-articles/how-to-invoke-workflows-from-another-workflow


#3

Hi,

As i am running to extract email. i already got the backbone out for 1 day for example 18 sep. But i need it to extract mail from 16 and 17 too. Total 3 days.

How can I do that?


#4

“[Received] >= '”+FileDate+" 00:00’ AND [Received] <= ‘"+FileDate+" 23:59’" I wrote this to specify the date. for filtering string


#5

You can store this dates in array and use them in loop. Using Invoke Workflow File you can pass these dates as Arguments. Other method that you can use is using For Each Activity. Just make array with dates and use it in for each loop


#6

Hi,

But the date will not always be the same… Is ui path able to specify day? like saturday sunday Mon tgt with the dates


#7

Hi,

You can use custom date format to get day of week: https://docs.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings. To get current date you can use DateTime.Now property


#8

Thank you(: