Hi there,
I have a frustrating issue with Try Catch action that’s set up to catch a timeout error but won’t - the try action throws the very same error the catch is supposed to .. catch.
Currently the whole process is set up as a loop with a list of items that are being searched. Everything prior to the Try Catch is working fine, but it’s the Try that’s messing up. As seen in the photo, it’s supposed to find a very specific element (when the element is available, it works fine) and if it won’t see it, then a timeout error is coming up. The Catch is to get every kind of error - I have also tried to specify and add some random others, but nothing have worked.
For some reason, when the process is being run (as file, debug or even just as “run”) the whole process stops at the Try action showing up the timeout error. i’ve been stuck at this for hours and can’t get it right
Can you check if you have global exception handler enabled in your project?
Project is expected at error when running in debug mode. But if it’s stopping in “run” mode, it can be the doing of global handler.
Hi everyone, thank you for your time helping me out on this.
Sadly nothing has helped and the try catch has proved to be a bit useless for me in that scenario.
Luckily I was hinted about Check App State that provided helpful and worked as intended.
You can try this below activities may help you to resolve your issue
UiPath sometimes throws a different type of exception than you expect.
For example, some activities (like “Click” or “Type Into”) under the hood throw:
UiPath.Core.ElementOperationException
or UiPath.Core.SelectorNotFoundException
instead of TimeoutException.