cancel
Showing results for 
Search instead for 
Did you mean: 

Problem connecting to SAP .NET Connector in 64 bit

Former Member
0 Kudos

In my .NET Application I have a 32bit DLL built using Visual studio 2003 to get custom data from SAP.

It works fine in Windows 7 (32bit). But it fails when I put the application in 64 bit Win 2008 server throwing below.

Error: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)

Stack:

at SAP.Connector.Connection.Open()

at eAcT_Leisureline.eAcT_Leisureline.GetProductionOffStandardsData(ZPRD_OFFSTable& gt_ZPRD_OFFS, ZPRD_OFFCTable& gt_ZPRD_OFFC)

at AMN.RFC_Grpah_Gen.Generate_OffStd_Graph()

Why it is not possible to run this 32 bit simple app. in 64 bit. Any workaround would be really appreciated. thanks.

Accepted Solutions (1)

Accepted Solutions (1)

former_member645959
Discoverer
0 Kudos

Perhaps you are compiling your application for "Any CPU", this won't be a problem when both compiling and running in a 32 bits OS.

However it will have the effect you mentioned if the application is ran on a 64 bit OS.

Try compiling the application targetting it for win32, that should do the trick.

Former Member
0 Kudos

Yes, It's working after setting the CPU. Thanks.

Answers (0)