cancel
Showing results for 
Search instead for 
Did you mean: 

call FM in BEx 7.2

Former Member
0 Kudos

I have macros in BEx 7.2 report calling FM from BW. In BEx 3 it's all right but in BEx 7 russian symbols of inport/export parametrs  are displayed like symbol "?".
I do this

Dim sapConnection As Object

    Set sapConnection = Run("BEXAnalyzer.XLA!sapBEXgetConnection")

    Dim sapFunctions As Object

    Set sapFunctions = CreateObject("SAP.Functions")

    Set sapFunctions.Connection = sapConnection

    Dim sapFunction As Object

    Set sapFunction = sapFunctions.Add("ZMY_FM")

    sapFunction.Exports("PARAM").Value = "Параметр"

But parametr  sapFunction.Exports("PARAM").Value = "????????"

Many pepople solved the problem using SAP.Functions.Unicode like this

Dim sapConnection As Object

    Set sapConnection = Run("BEXAnalyzer.XLA!sapBEXgetConnection")

    Dim sapFunctions As Object

    Set sapFunctions = CreateObject("SAP.Functions.Unicode")

    Set sapFunctions.Connection = sapConnection

    Dim sapFunction As Object

    Set sapFunction = sapFunctions.Add("ZMY_FM")

    sapFunction.Exports("PARAM").Value = "Параметр"

But in my case I have

sapFunction = Empty

sapFunction.Exports("PARAM").Value = Object required

some people had the problem due to missing file wdtlogU.ocx in directory c:\Program Files\Common Files\SAP Shared\

I have the file there.

We tryed to install SAP GUI 7.2 SP17  but we still have the problem

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member182470
Active Contributor
0 Kudos

Basically it's a Unicode problem. Your Russian letters are not able to interpret in your system.

Have you tried with the code what others have used to solve this problem?


But in my case I have

sapFunction = Empty

sapFunction.Exports("PARAM").Value = Object required

Why don't you change your code as per the right code what you have collected?

Former Member
0 Kudos

what do you mean?
I tried with

SAP.Functions

and  got

sapFunction.Exports("PARAM").Value = "????????"

I tried with

SAP.Functions.Unicode

and got

sapFunction = Empty

sapFunction.Exports("PARAM").Value = Object required

I checked file wdtlogU.ocx.

I tried to write codepage

sapFunctions.Connection.CodePage = "1504"

and

sapFunctions.Connection.CodePage = "1251"

and

sapFunctions.Connection.CodePage = "1252"

and

sapFunctions.Connection.CodePage = "8600"

too

I tried to change language.

I checked it on BEx 7.30

Former Member
0 Kudos

in Tools/references I get next library

Visual Basi for Applications

Microsoft Excel 14/0 Object Library

OLE Automation

Microsoft Office 14/0 Object Library

Microsoft Forms 2.0 Object Library

SAP BEx Analyzer API

maybe I need to add some one else ?

former_member182470
Active Contributor
0 Kudos
But in my case I have

This caused the confusion. I thought you have used like that. BUt now it is clear that you have got like that.

Can you debug your MAcro to know further?

Is Russian language installed in your system? Check in I18N t-code.

Former Member
0 Kudos

sorry, Suman)))

Yes, I can debug.


sapFunction = Empty

sapFunction.Exports("PARAM").Value = Object required

and

sapFunction.Exports("PARAM").Value = "????????"

I watch it in debug

Yes, Russian language is installed.

In BEx 3 we have not the problem in calling FM with russian parametrs but in BEx 7 it does not want to work.