on 2024 Jul 31 7:17 AM
I have come across a rather annoying bug in GUI scripting when connecting to SAP via GetObject(“SAPGUI”). This bug occurs for me both in Excel VBA as well as with Python3:
At a certain point, a connection to SAP can no longer be established if SAP is opened alternately by script and manually. Some time ago I posted this post on StackOverflow, unfortunately without any answers. At that time, the problem occurred mainly when alternating between manually calling the Logon Pad and the sapshut.exe. Now I have the same problem, although the programmatic start of SAP is also done via the Logon Pad and no longer uses sapshut.exe which I thought was a workaround.
The fastest way to reproduce this behavior is for me:
Has anyone ever encountered the same problem? Is SAP perhaps entered differently in ROT and “SAPGUI” is not always fitting?
Hello @Jan_Br,
welcome in the SAP Community. It seems to be a thorny problem. I remember that there was a similar problem before, or maybe even the same one. Please look at SAP Note 552646 - Sapshortcut: no Scripting, ... It is very old for SAP GUI 6.40 and has no relevance here, but good to know.
On the way you described I could not reproduce the problem. Somtime I was able to see the behavior, but unfortunately I do not know how the status can be achieved. After a restart, everything worked as expected again. I assume that the alternating use of saplogon.exe and sapshcut.exe probably causes the problem, but I can't say that for sure.
What could be possible solutions?
Best regards
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
57 | |
11 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.