Repeat activity and constructs

Hello everyone. I am new in UiPath. I have few questions. So, which activity can repeat activities within specified time range, and what type of constructs should i use to store undefined number of variables in the memory of the same type. I have watched and read all information that UiPath gives but can not find some.Please write something or just share useful links. Thank you.

I can think of below ways

  1. Replay event
  2. retry scope
  3. using a while loop
1 Like

To add to what @vvaidya posted,

If you can detect how much time is passed then you can exit a loop after a time period. You can do this by storing current time before the loop, then assign current time during the loop and compare both values to a System.Timespan variable/value (i.e. 00:05:00 for 5 mins).

For example,
nowTime = Now
Assign looptime = Now
While (looptime - nowtime < timespan)

or with a Retry Scope you can set how many Retries instead pretty easily in the parameters, but is used mostly for Exception catches. For example, if you have an unstable website portal to log in to, you can Retry multiple times if the site fails on you.

To use a condition in Retry Scope do a search for “Expressions” or “Is” and use one of those, mainly “Is True”. You can use similar logic as a Do While with it if desired.


1 Like

You could use stopwatch (System.Diognostics) instead.


Thank you! Can you please help me the second question - what type of constructs should use to store undefined number of variables in the memory of the same type.

You can store the variables in a List which has dynamic memory allocation.

Or a dictionary

Thank you very much!