Tarmac22

Hi

This is my first post, and I am very new to web services so forgive me if I don't express this too well.

I have been given the job of creating a client application to connect to an existing external web service. I have been provided with the wsdl, xsd and various other example xml files.

The application will need to pick up an XML file from the local network and pass it through the webservice.

I am trying to create a proxy by using the Visual Studio 2005 command prompt.

wsdl /o:BulkClaim.cs D:\PCOLBulkClaim\BulkClaim.wsdl

It fails stating

ERROR: Unable to import binding 'BulkClaimSoapBinding' from namespace 'http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim

-Unable to import operation 'processMortgageClaim'

- The datatype 'http://xml.apache.org/xml-soap:Element' is missing

If anyone can point me in the right direction I would be very grateful.

Thanks

Marc



Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Pablo Cibraro

Hi Marc,

It seems to be a problem with the WSDL or something is not compatible with the tool "wsdl". Is the Wsdl to big to post it here

Regards,

Pablo.






Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Tarmac22

Hi Pablo

Thanks for the reply. I have pasted the WSDL content below. Really grateful for any help I can get.

Marc.

< xml version="1.0" encoding="UTF-8" >

<wsdlBig Smileefinitions targetNamespace="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:intf="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:tns1="http://impl.service.bulkclaim.webservice.pcol.dca.gov.uk" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<!--WSDL created by Apache Axis version: 1.2

Built on May 03, 2005 (02:20:24 EDT)-->

<wsdl:types>

<schema elementFormDefault="qualified" targetNamespace="http://impl.service.bulkclaim.webservice.pcol.dca.gov.uk" xmlns="http://www.w3.org/2001/XMLSchema">

<import namespace="http://xml.apache.org/xml-soap"/>

<element name="mortgageRequest" type="apachesoap:Element"/>

<element name="rentalRequest" type="apachesoap:Element"/>

</schema>

<schema elementFormDefault="qualified" targetNamespace="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns="http://www.w3.org/2001/XMLSchema">

<import namespace="http://xml.apache.org/xml-soap"/>

<element name="processMortgageClaimReturn" type="apachesoap:Element"/>

<element name="processRentalClaimReturn" type="apachesoap:Element"/>

</schema>

</wsdl:types>

<wsdl:message name="processRentalClaimResponse">

<wsdlStick out tongueart element="implStick out tonguerocessRentalClaimReturn" name="processRentalClaimReturn"/>

</wsdl:message>

<wsdl:message name="processMortgageClaimRequest">

<wsdlStick out tongueart element="tns1:mortgageRequest" name="mortgageRequest"/>

</wsdl:message>

<wsdl:message name="processMortgageClaimResponse">

<wsdlStick out tongueart element="implStick out tonguerocessMortgageClaimReturn" name="processMortgageClaimReturn"/>

</wsdl:message>

<wsdl:message name="processRentalClaimRequest">

<wsdlStick out tongueart element="tns1:rentalRequest" name="rentalRequest"/>

</wsdl:message>

<wsdlStick out tongueortType name="BulkClaimServiceImpl">

<wsdlSurpriseperation name="processMortgageClaim" parameterOrder="mortgageRequest">

<wsdl:input message="implStick out tonguerocessMortgageClaimRequest" name="processMortgageClaimRequest"/>

<wsdlSurpriseutput message="implStick out tonguerocessMortgageClaimResponse" name="processMortgageClaimResponse"/>

</wsdlSurpriseperation>

<wsdlSurpriseperation name="processRentalClaim" parameterOrder="rentalRequest">

<wsdl:input message="implStick out tonguerocessRentalClaimRequest" name="processRentalClaimRequest"/>

<wsdlSurpriseutput message="implStick out tonguerocessRentalClaimResponse" name="processRentalClaimResponse"/>

</wsdlSurpriseperation>

</wsdlStick out tongueortType>

<wsdl:binding name="BulkClaimSoapBinding" type="impl:BulkClaimServiceImpl">

<wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>

<wsdlSurpriseperation name="processMortgageClaim">

<wsdlsoapSurpriseperation soapAction=""/>

<wsdl:input name="processMortgageClaimRequest">

<wsdlsoap:body use="literal"/>

</wsdl:input>

<wsdlSurpriseutput name="processMortgageClaimResponse">

<wsdlsoap:body use="literal"/>

</wsdlSurpriseutput>

</wsdlSurpriseperation>

<wsdlSurpriseperation name="processRentalClaim">

<wsdlsoapSurpriseperation soapAction=""/>

<wsdl:input name="processRentalClaimRequest">

<wsdlsoap:body use="literal"/>

</wsdl:input>

<wsdlSurpriseutput name="processRentalClaimResponse">

<wsdlsoap:body use="literal"/>

</wsdlSurpriseutput>

</wsdlSurpriseperation>

</wsdl:binding>

<wsdlTongue Tiedervice name="BulkClaimServiceImplService">

<wsdlStick out tongueort binding="impl:BulkClaimSoapBinding" name="BulkClaim">

<wsdlsoap:address location="http://vtpcol03:8888/pcol/services/BulkClaim"/>

</wsdlStick out tongueort>

</wsdlTongue Tiedervice>

</wsdlBig Smileefinitions>





Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

JoeMensor

Any luck with this, I'm doing the same thing...



Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Binoj Rajan

this could be because of the following two bugs reported by microsoft. you can click the following links for the workaround

http://support.microsoft.com/default.aspx scid=kb;en-us;317611

http://support.microsoft.com/kb/820122

thanks






Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Tarmac22

Hi Guys

Thanks for the replies. Sorry for the delayed response but I have been away for a bit.

I am planning to resume work on this tomorrow so I will let you know how I get on with the workarounds etc.

Thanks

Marc





Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

abil

Did you get anywhere with this I'm developing the same application for a different firm and getting the same error

Thanks





Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

abil

Did you get anywhere with it



Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

cosmos38240

Hi,

I have modified your wsdl, perhaps this can help you a little more, the old problem is fixed but I have a new one ...

Code Snippet

< xml version="1.0" encoding="UTF-8" >

<definitions targetNamespace="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:intf="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns:tns1="http://impl.service.bulkclaim.webservice.pcol.dca.gov.uk" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<!--WSDL created by Apache Axis version: 1.2

Built on May 03, 2005 (02:20:24 EDT)-->

<types>

<schema elementFormDefault="qualified" targetNamespace="http://impl.service.bulkclaim.webservice.pcol.dca.gov.uk" xmlns="http://www.w3.org/2001/XMLSchema">

<apachesoap:element name="mortgageRequest" type="apachesoap:Element"/>

<apachesoap:element name="rentalRequest" type="apachesoap:Element"/>

</schema>

<schema elementFormDefault="qualified" targetNamespace="http://uk.gov.dca.pcol.webservice.bulkclaim.service/BulkClaim" xmlns="http://www.w3.org/2001/XMLSchema">

<apachesoap:element name="processMortgageClaimReturn" type="apachesoap:Element"/>

<apachesoap:element name="processRentalClaimReturn" type="apachesoap:Element"/>

</schema>

</types>

<message name="processRentalClaimResponse">

<part element="implrocessRentalClaimReturn" name="processRentalClaimReturn"/>

</message>

<message name="processMortgageClaimRequest">

<part element="tns1:mortgageRequest" name="mortgageRequest"/>

</message>

<message name="processMortgageClaimResponse">

<part element="implrocessMortgageClaimReturn" name="processMortgageClaimReturn"/>

</message>

<message name="processRentalClaimRequest">

<part element="tns1:rentalRequest" name="rentalRequest"/>

</message>

<portType name="BulkClaimServiceImpl">

<operation name="processMortgageClaim" parameterOrder="mortgageRequest">

<input message="implrocessMortgageClaimRequest" name="processMortgageClaimRequest"/>

<output message="implrocessMortgageClaimResponse" name="processMortgageClaimResponse"/>

</operation>

<operation name="processRentalClaim" parameterOrder="rentalRequest">

<input message="implrocessRentalClaimRequest" name="processRentalClaimRequest"/>

<output message="implrocessRentalClaimResponse" name="processRentalClaimResponse"/>

</operation>

</portType>

<binding name="BulkClaimSoapBinding" type="impl:BulkClaimServiceImpl">

<wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>

<operation name="processMortgageClaim">

<wsdlsoap:operation soapAction=""/>

<input name="processMortgageClaimRequest">

<wsdlsoap:body use="literal"/>

</input>

<output name="processMortgageClaimResponse">

<wsdlsoap:body use="literal"/>

</output>

</operation>

<operation name="processRentalClaim">

<wsdlsoap:operation soapAction=""/>

<input name="processRentalClaimRequest">

<wsdlsoap:body use="literal"/>

</input>

<output name="processRentalClaimResponse">

<wsdlsoap:body use="literal"/>

</output>

</operation>

</binding>

<service name="BulkClaimServiceImplService">

<port binding="impl:BulkClaimSoapBinding" name="BulkClaim">

<wsdlsoap:address location="http://vtpcol03:8888/pcol/services/BulkClaim"/>

</port>

</service>

</definitions>

Have fun Smile





Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Daniel Roth

When you use the wsdl.exe tool with files on the local file system you must pass all necessary files on the command-line. In your case, the WSDL imports an XML Schema document, but you are only providing the WSDL document, so the tool complains that it can't find the schema type definitions. You need to pass the XML Schema to the tool along with the WSDL doc.

If you point wsdl.exe at the URI for a WSDL, then the tool will take care of retrieving all of the necessary files for you.

Daniel Roth






Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

abil

Hi and thanks for your reply.

Could you tell me the syntax for this I have a few XSD files in C:\projects\PCOL\ along with the WSDL file in the same folder.

I've had a look around the web but can't seem to find anything that uses local xsd files.

Thanks in advance





Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Neil Clark

What is the syntax to create the proxy file from this WSDL Do I need the xsd defining the apachesoap:Element

Thanks in advance.




Re: ASMX Web Services and XML Serialization WSDL.EXE - Cannot create proxy file

Nabil79

open a command window and go to

C:\Program Files\Microsoft Visual Studio .NET\FrameworkSDK\Bin\

type wsdl and it will give you all the options. If you're wantign a C# file then the systax would be

wsdl /o:BulkClaim.cs D:\PCOLBulkClaim\BulkClaim.wsdl

Good Luck

Nabil