Search code examples
c#soapdatahandler

How can I consume a Java based SOAP service that uses a Datahandler type in C#


I'm trying to consume a SOAP service (Agile PLM webservice) using C#, but the SOAP service uses a "Datahandler" type, which seems to be language specific to Java (using Apache Axis library as far as I can tell).

When I try to use the wsdl.exe tool to create a proxy class, it fails due to not having a type for this datahandler. Can anybody suggest how to (cleanly, efficiently) consume this SOAP service without having to hand code a proxy class or manually deal with the SOAP messages in C#?


Solution

  • First of all, unless you're stuck using .NET 2.0, you shouldn't be using WSDL.EXE. You should be using SVCUTIL.EXE or "Add Service Reference".

    In any case, that wouldn't help you consume this broken web service.

    Some versions of Apache services that I have seen effectively assume that the consumer is also running Java, and in fact, that it already knows about these data types. That's just plain broken, and cannot be fixed, except by the vendor of the broken web service.

    I was under the understanding that later versions of Apache fixed these problems by including the definition of these types in the WSDL.