![]() |
|
|||||||
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| XL Reporter Error - Error Starting Excel! Cause: (Retrieve Excel Interface) | Lala | SBO - SAP Business One | 2 | 05-13-2011 06:59 PM |
| HU items' material posting is inconsistent - Error Message HUGENERAL327 | Micro | SAP SD - Sales & Distribution | 1 | 04-19-2011 09:43 PM |
| Error Message KI339 | ERP | SAP FI CO - Financials and Controlling | 1 | 01-26-2011 09:10 PM |
| RS_VARIANT_CONTENTS - Message Error : "Obsolete variants". | Pepa | SAP ABAP | 2 | 08-30-2010 02:16 PM |
| Call transaction background mode + error message DC006 Control framework | Lala | SAP ABAP | 2 | 08-27-2010 01:45 PM |
| Aprenda SAP! |
|
|
![]() |
|
|
Thread Tools | Display Modes |
|
#1
|
|||
|
|||
|
Hello experts,
When GuiXT is activated and the following script is executed from excel macro Pop up message "Can not find GuiXT component, check the installation"is displayed. When GuiXT is deactivated no error message is displayed. What can be done to avoid this pop up ? If Not IsObject(SapGuiApp) Then Set SapGuiApp = CreateObject("Sapgui.ScriptingCtrl.1") End If If Not IsObject(Connection) Then Set Connection = SapGuiApp.OpenConnection("QA", False) End If If Not IsObject(Session) Then Set Session = Connection.Children(0) End If If how = "maximize" Then Session.findById("wnd[0]").maximize Else If how = "iconify" Then Session.findById("wnd[0]").iconify Else Session.findById("wnd[0]").iconify End If End If Session.findById("wnd[0]/usr/txtRSYST-MANDT").Text = "400" Session.findById("wnd[0]/usr/txtRSYST-BNAME").Text = "USER" Session.findById("wnd[0]/usr/pwdRSYST-BCODE").Text = "PASS" Session.findById("wnd[0]/usr/txtRSYST-LANGU").Text = "EN" Session.findById("wnd[0]/usr/txtRSYST-LANGU").SetFocus Session.findById("wnd[0]/usr/txtRSYST-LANGU").caretPosition = 2 Session.findById("wnd[0]").sendVKey 0 ...... Thanks in advance, Rampa |
| Sponsors |
|
#2
|
|||
|
|||
|
Hi Rampa,
The object "Sapgui.ScriptingCtrl.1" does not support the GuiXT. So the error does not come, you must first disable GuiXT. Or you can use a helper script. For example: Code:
set wshell = createObject("Wscript.Shell")
wshell.run "./script_activate.vbs Information"
If Not IsObject(SapGuiApp) Then
Set SapGuiApp = CreateObject("Sapgui.ScriptingCtrl.1")
End If
. . .
Code:
if wscript.arguments.count > 0 then
window_title = wscript.arguments(0)
set wshell = createobject("Wscript.Shell")
number = 0
Do
bWindowFound = Wshell.AppActivate(window_title)
WScript.Sleep 500
number = number + 1
if number > 10 then exit do
Loop Until bWindowFound
wscript.sleep 200
Wshell.AppActivate window_title
wscript.sleep 200
wshell.sendkeys "{Enter}"
wscript.sleep 200
end if
Regards, Golfi |
| Entre a los Links relacionados |
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|