SAP locked, locked bot


I have a bot in productive about 2 years ago, this bot have automation with Excel and SAP desktop application, the issue is that SAP transaction lock the bot when is running, normally happen two or tree times at day. The bot have a internal counter (0 to 30) to wait transaction load but when transaction is lock, the bot is aslo lock and the bot execution be stop until SAP is unlocked, manually I have to kill SAP process and bot start the counter.

For internal counter i’m using Image exists and WaitForReady: NONE:


¿Any solution for this issue?

Thanks for your help

Try to remove this ImageFound Activity with a Element Exist.

And are you sure that the internal counter checked for 30 times and then got locked.

Are you using DoWhile loop to check the imagefound activity? When you connect manually are you seeing any popup or any overlay screen on top of SAP?

Hi Sarathi125,

Thanks for your answer, before Image Exists I was using Element exist and the result is the same, this is the way that i’m doing the internal counter:

The part where you say SAP is locked i dont understant but isnt one second to little time to wait for an image to be found? Are you saying here that that image is never found right?

Hi bcorrea, yea, one second is to little time, but since i’m using the counter, it is not a issue.

I’m saying that the robot execute is interrupted when SAP is locked and the code execute don’t continue. It’s like SAP take the control of bot execute and don’t allow anything until me join in the machine and kill process manually.

i mean you give it one second it would never be able to find it that fast so even if it is there it will fail always… So SAP will hang while your code is executing?

Ok, I will put 5 seconds to wait and I will tell you how it goes

finding images is not the same as finding elements by selectors, it is like ocr, takes some time…

Hi bcorrea,

I changed one second to five seconds and the result is the same, later I changed Image exists to Element exist and the result is the same.

well, i guess you have to work with your SAP tech guys to see what operation makes the SAP to lock…

It’s ok, I will to take with any SAP adviser.

Thanks for your help.

1 Like

Any result on this one? I’m having the same issue. When you execute a SAP transaction i.e. searching for invoice lines etc, UiPath gets stuck on that click ‘execute’ activity, until SAP has loaded the invoice lines. It’s only obvious when you debug and step it through. It’s like UiPath can’t speak with SAP until that job has executed.

Hey Matt,

First I will explain what was happening: the robot was loading to SAP an Excel file with some information to invoice, this Excel file contained macros as well as it could contain links to other files. Then what was happening was that SAP opened the Excel file and if the file contained a link then SAP was stuck.

The only solution I found was to take out the sheet of the Excel file that was to be uploaded to SAP, the other sheets of the file I simply left aside as supports for the request sent by the customer. This solved the problem that SAP was loading as it was uploading a flat file without any “garbage” information.
I hope you will find my recommendation useful.