'SAP BW Data pull in excel using vba
I am trying to get data from SAP BW using vba so far I have established a connection using the BEx connection found online not sure what would be the syntax to retrieve data from one of the queries/tables and change the parameters, any help will be valuable
Dim xl
Dim myConnection
Dim xlBook
Dim username As String
Dim password As String
Set xl = CreateObject("Excel.Application")
username = Worksheets("Data").Range("A1")
password = Worksheets("Data").Range("A2")
xl.Visible = True
xl.Workbooks.Open ("C:\Program Files (x86)\Common Files\SAP
Shared\BW\BExAnalyzer.xla")
xl.Run ("BExAnalyzer.xla!SetStart")
Set myConnection = xl.Run("BExAnalyzer.xla!sapBEXgetConnection")
With myConnection
.client = "100"
.user = username
.Password = pass
.Language = "EN"
.systemnumber =
.system = ""
.ApplicationServer = ""
.SAProuter = ""
.Logon 0, True
End With
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
