cancel
Showing results for 
Search instead for 
Did you mean: 

Calling XI web service from .net application (asynchron)

Former Member
0 Kudos

Hi all,

i want to call a XI web service from .net C# (asynchron).

rows.ORDER = "XX";

rows.SERIES_NUMBER = "XXXX";

rows.DEVICE = "XXXX";

rows.BIN = "XXXX";

root.ROOT = new WebService.DT_BINRows[1];

root.ROOT.SetValue(rows, 0);

NetworkCredential credentials = new NetworkCredential(user, pass);

proxy.Credentials = credentials;

IAsyncResult ar = proxy.BeginMI_BIN_OUT(root, new AsyncCallback(CallbackSampleMethod), root);

proxy.MI_OUTAsync(root);

private void CallbackSampleMethod(IAsyncResult asyncResult)

{

((WebService.MI_BIN_OUTService)asyncResult.AsyncState).EndMI_BIN_OUT(asyncResult);

}

What's wrong?

regards

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

i have found my error.

At the interface name was one letter missing.

regards

Former Member
0 Kudos

Hi,

thanks.

The web service call should be asynchron!!!

We have another example which is used by an external company and there it is running successfully.

But i don't know how they have made it.

Any ideas?

regards

VijayKonam
Active Contributor
0 Kudos

Hi Wolfgang,

This is XI forum. Not all the people here are expets in Java or .NET or even ABAP. ITs a mixed ground. IF you could let us know the error you are getting, we might be able to help you.

Are you asking about any complie error or runtime error or any access related??

VJ

Former Member
0 Kudos

Hi,

i see in SXMB_MONI that a message is received.... but synchron!!

And an error occured.....

The received message has no header like <xml version=1.0 ....>

I see the following:

<MT_BIN xmlns="http:......> and the values

Any ideas?

regards

VijayKonam
Active Contributor
0 Kudos

The XI outbound interface must have been defined as Synchronous and then the WSDL was generated. Ask the XI counter points so that they can look into this issue and give you a fresh WSDL generated.

VJ

VijayKonam
Active Contributor
0 Kudos

Also,

Look like, since you are using a call back function, it might be the case that the Web Service is actuallyy synchrnous in nature but you are trying to call it asynchronously, and then use this call back function for processing the response.. Just a thought..

In that case, SXMB_MONI would show it as Sync only..

VJ