I am trying to establish connection using SAP GUI from Excel VBA and keep getting the same 424 error.
Runtime Error 424 “Object Required”
I've tried multiple ways changing variables but nothing seems to be working for me :(
If Not IsObject(Application) Then
Set SapGuiAuto = GetObject("SAPGUI")
Set Applicationa = SapGuiAuto.GetScriptingEngine
End If
If Not IsObject(Connection) Then
Set Connection = Applicationa.Children(0)
End If
If Not IsObject(session) Then
Set session = Connection.Children(0)
End If
If IsObject(WScript) Then
WScript.ConnectObject session, "on"
WScript.ConnectObject Application, "on"
End If
session.findById("wnd[0]").resizeWorkingPane 131, 25, False
session.findById("wnd[0]/usr/cntlIMAGE_CONTAINER/shellcont/shell/shellcont[0]/shell").doubleClickNode "F00006"