Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3353

Help on Sapbexsetvariables Analyzer (BW 3.x) VBA

$
0
0

Dear All, i'm looking for some help on the code below. It's running fine until:

 

Set rngVar = WorkSheets("Sheet2").Range(“A2:H3”)

 

 

Run "SAPBEXsetVariables", rngVar

 

I have created a sheet with variables by method i found elsewhere (sapbexDebugprint).

 

Any pointers on how to finish the code? The full code is:  

 

 

Function LogonToServer() As Boolean

   LogonToServer = False

   Dim myConnection As Object

   Set myConnection = Run("sapbex.xla!SAPBEXgetConnection")

   With myConnection

      .client = "700"

      .user = "XXX"

      .Password = "XXX"

      .Language = "EN"

      .systemnumber = 3

      .system = "39. BBP Europe BW Production"

      .ApplicationServer = "XXX"

      .SAProuter = ""

      .logon 0, True

   End With

   If myConnection.IsConnected <> 1 Then

      'launch the Logon Dialog for manual connection

      myConnection.logon 0, False

         If myConnection.IsConnected <> 1 Then

            MsgBox "something went wrong ..."

            Exit Function

         End If

   End If

   If myConnection.IsConnected = 1 Then

      LogonToServer = True

   End If

   Run "sapbex.xla!SAPBEXinitConnection"

   Run "sapbex.xla!SAPBEXrefresh", True

 

'Code runs upto here

 

 

Set rngVar = WorkSheets("Sheet2").Range(“A2:H3”)

 

 

Run "SAPBEXsetVariables", rngVar

 

 

 

 

End Function


Viewing all articles
Browse latest Browse all 3353

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>