0

I am continuing from How to use a WSDL. I got a WSDL file from our vendor. I have added as Service Reference in Visual Studio 2010. Getting the below 2 errors.

    Warning    1    Custom tool warning: Cannot import wsdl:portType
Detail: An exception was thrown while running a WSDL import extension: System.ServiceModel.Description.XmlSerializerMessageContractImporter
Error: Choice is not supported with encoded SOAP. Please change definition of schema type 'MessageData' from namespace 'http://somethinghere': use all or sequence (not choice) for fields/parameters.
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://somethinghere']/wsdl:portType[@name='SoSPortType']     C:\ \Reference.svcmap 1    1    Decoder_CLI

    Warning    2    Custom tool warning: Cannot import wsdl:binding
Detail: There was an error importing a wsdl:portType that the wsdl:binding is dependent on.
XPath to wsdl:portType: //wsdl:definitions[@targetNamespace='http://somethinghere']/wsdl:portType[@name='SoSPortType']
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://somethinghere']/wsdl:binding[@name='SoSSoapBinding']     C:\\Reference.svcmap 1    1    Decoder_CLI

There are many such posts available for this type of warning, but for my specific error

Error: Choice is not supported with encoded SOAP

I cannot find any solution. Any help is welcome. btw I have already tried as Web reference, Un-checking of "Reuse types in referenced assemblies" etc. and all such other solutions already available on the internet.

UPDATE

Forgot to mention. I also tried to add this WSDL as a SOAP project On SoapUI client and without any errors was able to consume it.

Community
  • 1
  • 1
WoodyStory
  • 471
  • 1
  • 4
  • 9

0 Answers0