Do Until Loop and For Loop

We have While and Do While loops available, but VB.NET also has Do Until loops - I understand all logic can be flipped in a normal While/Do While loop, but it makes it less readable. It would be nice to have the option to use a Do Until loop as well.

Same thing goes for For Loop. We have For Each, but don’t have For loops. There are tons of times I need to use a for loop and have to approximate it by doing for each i in Enumerable.Range(0,21) instead of For i as Integer = 0 to 20. It is possible, but not immediately obvious to recreate loops. It is also very difficult to iterate through a for loop backwards or using any other logic besides i++ using the current workaround

Hi @Dave,

Does “Invoke Code” activity not work for you?

Hi @rmunro thank you for the response! Invoke code does work so long as everything within your For Loop is written in C#/VB.NET code. Having it available as an activity allows other uipath activities to be used within the loop.


You’re right @Dave,

You got my vote.

Hi, i am using two for-each loop i want first for-each loop get value1 and second for-each loop get value1 after getting value1 from 2nd for-each it has to return to 1st for-each loop.I have given my screenshot and myproject given below .
InvoiceDemo (2).zip (268.7 KB)

Thank you for your suggestion. I added it to our internal ideas tracker for our team to consider.