Bot won't create new Excel file

One of our business units decided to restructure a few of their folders and as a result, I had to update a few of our bots so they can read/write to and from the new directory. Almost all the bots worked fine after reprogramming, but one, in particular, isn’t responding as expected.

I have triple-checked the file directory in the bot, correct permissions within Excel, and directory access within our RDP VM. The bot is failing at this Excel step where it’s supposed to write a log of the table it just queried. I tried setting the path to an Output argument and using that instead, but it didn’t work. I also tried a Write Range workbook activity to create the file but the error message said “access to the path [path] is denied.” The remote user this bot runs on DOES have access to the target directory so I’m not sure why it says the access is denied.


For a day after I implemented these changes originally, the bot worked fine but as of yesterday, it’s now failing where it shouldn’t be. This bot has worked for a LONG time and I’ve tried just about everything I can think of to get it running again. Has anyone experienced anything similar to this?

Running on Enterprise version 2021.4 with the following dependencies.
“UiPath.Database.Activities”: “[1.6.1]”,
“UiPath.Excel.Activities”: “[2.12.3]”,
“UiPath.Mail.Activities”: “[1.15.2]”,
“UiPath.System.Activities”: “[22.4.5]”,
“UiPath.UIAutomation.Activities”: “[22.4.7]”

@Kyle_Shahenian Before opening excel file please kill all excel process by using kill process activity, maybe it work in this scenario.

No Excel processes were open at the time of running.

@Kyle_Shahenian I am talking about background.

So was I. Went into task manager and didn’t see a lick of Excel in there.

@Kyle_Shahenian sometime we are able to see process

Hello @Kyle_Shahenian,

You just make sure the file where you are tying to input the logs is not the shared file, as sometime on the shared network people forget to close the file and second use the kill process activity and under the ProcessName pass the string as Excel and then go to write the log.

Thanks,
Sanjit

Hello, @Kyle_Shahenian - Can you try keeping the same file in your documents folder and run the bot. Check will it be able to access the file without any issues. If so, then there must be an access issue with your G drive

In this instance, the bot is having trouble writing a NEW log. In my Excel Application Scope properties, I have “Create if doesn’t exist” set to true. Nobody has been in or out of the file as it doesn’t exist yet.

If it were a G drive access issue, then the RDP user itself wouldn’t be able to access that drive. That is not the case with this issue.

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