0
votes

I am connecting my local system with SAP server using BizTalk adapter and also using Microsoft.servicemodel.channels to open the connection in sap to process XML as input file.

            SAPBinding binding = new SAPBinding();
            binding.ReceiveTimeout = TimeSpan.MaxValue;
            binding.SendTimeout = TimeSpan.MaxValue;
            binding.EnableBusinessObjects = true;
            binding.EnableSafeTyping = true;

         EndpointAddress address = new EndpointAddress(SAPConnectionString);
ChannelFactory<IRequestChannel> factory = new ChannelFactory<IRequestChannel>(binding, address);

// add credentials
factory.Credentials.UserName.UserName = SAPUserName;
factory.Credentials.UserName.Password = SAPPassword;

// Open client
factory.Open(TimeSpan.MaxValue);

Factory.open cannot open the connection and it through an exception as A specified module could not be found, (Exception from HRESULT : 0x8007007E)

Kindly please help me

thanks in advance.

1
Please also show the assignment of variable binding?Gruff
yes @Gruff i edited my question please help me outGopal Krishnan
Is this code are enough for you.Gopal Krishnan
Unfortunately not. It looks like there is a dependency on an assembly it is unable to find. Perhaps take a look at this: stackoverflow.com/questions/2522009/…Gruff
sorry @Gruff i couldn't share the full code. thanks for your reply, but the application created by someone but i want to fix this problem,it works on windows server (2008 R2).This application passes all the xml file to sap except only one with this error(Invalid character in the given encoding. Line 1, position 1374.) i checked the whole xml file also. May i know windows 8.1 is acceptable os to run biztalk or windows server os is need? because i deploying this application in 8.1 and also am new to sap alsoGopal Krishnan

1 Answers

0
votes

The error message suggests there is a dependency on an assembly it is unable to find. Please note this is not something specific to WCF or the SAP adapter.

Googling for "HRESULT: 0x80070007E" I found: C# Unable to load DLL (Module could not be found HRESULT: 0x8007007E)

In David Heffernan's answer he recommends using tools like Dependency Walker to help debug dependency issues.