How do i put File not found exception for Excel in uipath?

How do i put File not found exception for Excel in uipath?
Even if the file is not in the specified path, It creates one using excel application scope activity.
My requirement is not to create a file, if it does not find the specified file. Instead it should throw the exception message.

How do i achieve this?

Hey @Mallika

You can uncheck the “Create New File” property of the Excel Apllication Scope from the properties panel on the right side of the screen to get the exception!

Hope it helps :slight_smile:

Regards.

2 Likes

otay , so even though there is probably a system.exception file not found , here , using the “path exists” activity , you can set an if statement to throw a business exception if file not found … see the xaml attached

Main.xaml (11.5 KB)

1 Like

Hi Rishabh,
Thanks for the response, however I do not see the Create New File option in the property pane:

Try reinstalling the excel activities package. Might work!

Great…It worked!!! Thanks a lot man!! Thank you Niket!!

1 Like