I am tired of searching and finding no clear answers.
So here is the situation. I have a vbscript file that automates the SAP GUI. My issue is that I need to get the status text from the status bar after every input is made.
I have tried using findById("wnd[0]/sbar").text, but it does not capture every warning or error message.
Does the status bar object have any other properties besides text?
Any type of response would be greatly appreciated.
-Thanks
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
Hi, the object to look for is type GuistatusBar
here is a VB sample
Function getStatus() As String
If IsNothing(sess) Then
Return "session is not connected"
Else
Return Me.sess.ActiveWindow.FindByName("sbar", "GuiStatusbar").text
End If
End Function
the demo examlpe in my script automation tool sends a /$TAB okcode to a sapgui and the retrieves the text in the statusbar
The tool is in SF is called lbscript
Regards
Btw, there is also a dumpscreen method which creates a text file with all the screen or window elements so you can retrieve them later on.
Here is the line which contains the statusbar message and type
"/app/con[0]/ses[0]/wnd[0]/sbar Name: sbar Type: GuiStatusbar Value: TAB buffer reset Read only Children:7"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.