How to handle exception in a workflow


can someone please advise me how to handle following exceptions?

My robot is donwloading files from web and I do not want the process to be stopped when he finds out that the file (name is created based on some rules) already exists. I want the bot to skip this file and continue downloading.

E.G. I have 10 files existing in my folder. One of them is 123456.pdf…the robot is downloading new files and it finds out that file 123456.pdf already exists. I need the robot to terminate downloading of this file and continuing with donwloading the following one so the complete flow is finished.

I do not know how to handle this.

Thank you for suggestions.


It might be a good idea to check whether the file is downloaded with Path Exists activity.

As an input, the file path is given and if it turns True, you skip the file with a throw activity, else you continue process.

Hope it works !


You can use Path Exists activity, which gives
If already file exists in the given folder->True
So Declare a output variable to Path Exists after that use IF condition and based upon the output you can determine your automation

Hope this may help you


Hello, that would mean that the bot will have to first serach for the file but since the name of new file is created during downloading I do not know how to do this.

My robot is performing some steps in email, then it opens a web page and there he opens pfd without any name and this pdf must be saved with specific name…and it can happen that someone aready run the robot and created the file and runnign the robot second time will have an error that the file already exist while trying to save it.


So, you do not name the downloaded file, but it takes a default name. Right ?

If so, you can download the file to a temp file, and get the file name. Then, use Path Exists activity to search whether there is a file with the same name in your final folder. If exists, you do nothing. If not, you copy that file to the final destination.

Hope it helps !

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.