Gaurav07
(Gaurav Bahuguna)
1
syntax -
For each item in array
{
assign
write range
.
.
.
}
This is surtrounded by try catch
suppose if an exception comes then can I use break activity in the catch block to skip current iteration and move to next iteration of for each…
or the break activity will exit the for each loop which I don’t want
1 Like
lakshman
(Ganta lakshman)
2
2 Likes
Vashisht
(Vashisht Devasani)
3
Hi @Gaurav07,
1.You cant use continue in catch, it will throw error you can use it only inside for each…

2.This will not help you to achieve your goal…
3.Try keeping the assign activity or the activity which you are expecting the exception and then keep continue in it…
4.so keep try catch inside for each…
Any doubts let me know…
Cheers.
Vashisht.
keep try catch inside for each loop and place continue in catch
1 Like
Break activity is used to exit from the loop.
Continue activity is used to skip the current iteration.
Regards,
Karthik Byggari
TryCatch inside For each? How?