cancel
Showing results for 
Search instead for 
Did you mean: 

C++ Visual Studio Problems

Former Member
0 Kudos

Hello...

I am trying to use the SAP Scripting in my MFC

application. I imported the ActiveX Element and

generated a class for it, derivered from CWnd.

The generated class konsists of some methods,

that uses the GuiComponent/GuiComponentCollection

datatyps. But i have no idea, where i can find the

definitions for that datatyp. Anybody can help???

Also, I commented those Methods to still try the code

and it is working. See the code:

if(m_SAPGui.Create(NULL, NULL, WS_BORDER, rc, this, IDC_SAP_GUI, NULL))

{

LPDISPATCH disp;

VARIANT v1, v2;

VariantInit(&v1);

VariantInit(&v2);

disp = m_SAPGui.OpenConnectionByConnectionString(L"servername", v1, v2);

}

This starts a Connection to SAP, but now i have a

IDispatch and do not know how i can work with it.

how can I work with it?? Any documentations on that?

how can i the QueryInterface method???

I am really stucked and any help would be very very

great!!

Thx

View Entire Topic
Christian_Cohrs
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Mesut,

the documentation is available at ftp://ftp.sap.com/pub/sapgui/win/640/scripting/docs/

Best regards,

Christian

Former Member
0 Kudos

thx for your post,

but that documentation is based on Visual basic.

That does not help me. But still i have resolved

my Problem....

The msdn article "How to create an automation project

using MFC and a type library" and the ole viewer

answered my problems...

still hx again!