on 2022 Aug 14 10:29 AM
hello, i have recently started to use vba in excel with sap. When im using the fmbb transaction in sap sometimes im getting a error. The error is always displayed in the error log. When i press right click on the error and press details i can see the line where the error is occurring. My question is how im getting the line of the error out of there with vba. Ive tried to use script records unsuccessfully. Thanks for the help.
Request clarification before answering.
I don't know the transaction, but if you mean the message that you get on the bottom left corner after executing, you can access this with:
Dim objSBar As GuiStatusbar
Set objSBar = session.FindById("wnd[0]/sbar")
Range("A1").Value = objSBar.Text
Range("B1").Value = objSBar.MessageId
Range("C1").Value = objSBar.MessageType
Range("D1").Value = objSBar.MessageNumber
Range("E1").Value = objSBar.Name
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.