Hi Allan,
I have a use case that involves downloading an excel file from a website, after the download this new file should overwrite an existing file in some folder.
I get stuck after clicking the download link. How do I proceed to use the new file/data to overwrite the old file?
Currently my final step is this:

Hope you can help
Best,
Jori
Since you download the file using a link, and not using some kind of activity in OpenRPA, you just need to come up with a replacement algorithm.
For example:
- The old file is marked with the postfix â_oldâ or â_forDeleteâ
- Download the file
- Delete the file with postfix
The algorithm should be adjusted if there are any special requirements for the RPA process (file name, speed, etc.)
Thanks for your reply, but unfortunately this is not exactly what Iâm looking for. Iâll try to explain a little bit more in detail what I need:
I have an excel file with a specific name in a specific folder (No postfix)
Every day, I want to replace this file (or overwrite the data in this file) with the new file/data I get from the download.
The file I download does not have the correct name yet and is not automatically downloaded to the correct folder.
So for example, the file I would like to replace looks like this:
Filename: âMyFile.xlsxâ
Folder: â\something\something\Desktopâ
The downloaded file is like this:
Filename: âNotMyFile.xlsxâ
Folder: â\something\something\Downloadsâ
In the end âNotMyFile.xlsxâ should become âMyFile.xlsxâ in folder â\something\something\Desktopâ
Hopefully this clarifies the use case better.
In this case, I would simply take the data from âNotMyFile.xlsxâ and put them in âMyFile.xlsxâ and then delete the first file
I understand that something like that is what needs to be done, only not how to achieve this. This is probably easy but Iâm quite new to OpenRPA.
So, what I would like to know is:
How to retrieve the data from the downloaded file?
How to put it in the correct file?
How to delete a file?
Hope you can help!
There is a feature built into the chrome extension for this exact case
Add âWait for downloadâ activity, and INSIDE that, do the click that triggers a download.
then AFTER the âWait for downloadâ use the event from âWait for downloadâ to get the filename of the downloaded file.
This will not overwrite the old file, but it WILL give you the current/new name.
Thank you very much for your reply, I think I figured it out!
One more question, Iâm now using ReadExcel and WriteExcel to extract the data from the downloaded file and update the correct file. The problem is that the downloaded file has a worksheet name starting with numbers, for example â1 sheetâ. Which results in this error:
The table name â1 sheetâ does not begin with a letter, an underscore or a backslash.
Is there a way to change the name of the Worksheet or another workaround?