Exception Type Not Showing in .Net Window when Adding Catch

I am using a Try/Catch to detect exceptions in my process. One of the exceptions that is thrown is the UiPath.Core.Activities.TypeInto exception. When trying to add this exception as a Catch, I am unable to find UiPath.Core.Activities.TypeInto in the search window. I have tried searching keywords as well.

Does anyone have a possible solution? Many thanks for your help.

1 Like

Hi @automationfinance

Sorry but i don’t get exactly what was the error. If you can share your xaml is much easier for us to address the issue. Many Thanks. :smiley:

cheers :smiley:

Happy learning :smiley:

1 Like

Hello,

Thank you very much for the reply. Unfortunately I cannot share the XML because it has sensitive information.

However, I can try to do a better job of explaining my issue. I am trying to use a “Try/Catch” activity to detect the following exceptions:

  1. UiPath.Core.Activities.ActivityTimeoutException
  2. UiPath.Core.SelectorNotFoundException
  3. UiPath.Core.Activities.TypeInto
  4. InvalidUiElementException

The first issue is that when an error occurs, the “Catch” is not detecting the exception and executing accordingly. You can see in the screenshot that a UiPath.Core.SelectorNotFoundException was thrown, but the selector_not_found_exception variable I have created is null. Why isn’t it catching the exception?

The second issue is that I cannot find the UiPath.Core.Activities.TypeInto exception in the .Net browser when I click on “Add New Catch.”

Any guidance would be greatly appreciated.Exception.pdf (782.9 KB)

Thanks!

Hi @automationfinance

By Using try catch activity
in Catch activity pass the exception

and assign strException=exception.Message

it is equal to all for all the exception types

  1. UiPath.Core.Activities.ActivityTimeoutException
  2. UiPath.Core.SelectorNotFoundException
  3. UiPath.Core.Activities.TypeInto
  4. InvalidUiElementException

Thanks
Ashwin S

Hello @AshwinS2,

Thanks for the reply.

I have that in each of my catch blocks and my finally block executes based on whether or not strException is Nothing. If it is Nothing, I continue the For Loop. If it is not nothing, it should execute a series of actions. Unfortunately it is not working for me.

Thanks again!