Custom WSDL, Error while adding as web reference


M

MD

Hi,

I am trying to add a custom WSDL file I created and add it in another
project. And I get the following error:

Custom tool error: Unable to import WebService/Schema. Element binding
named StockQuoteBinding from namespace http://myadvancedwebserviceURI/
is missing.

Any help will be of great help!.. Here is the WSDL file, I am not sure
if there is a error in here..

<?xml version="1.0"?>

<definitions
name="StockQuote"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:s0="http://myadvancedwebserviceURI/" xmlns:soapenc="http://
schemas.xmlsoap.org/soap/encoding/"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
targetNamespace="http://myadvancedwebserviceURI/"
xmlns="http://schemas.xmlsoap.org/wsdl/">

<types>
<s:schema targetNamespace="http://myadvancedwebserviceURI/">
<s:element name="TradePriceRequest">
<s:complexType>
<all> <s:element name="tickerSymbol" type="string"/> </all>
</s:complexType>
</s:element>
<s:element name="TradePrice">
<s:complexType>
<all> <s:element name="price" type="float"/></all>
</s:complexType>
</s:element>
</s:schema>
</types>
<message name="GetLastTradePriceInput">
<part name="body" element="s0:TradePriceRequest"/>
</message>
<message name="GetLastTradePriceOutput">
<part name="body" element="s0:TradePrice"/>
</message>
<portType name="StockQuotePortType">
<operation name="GetLastTradePrice">
<input message="s0:GetLastTradePriceInput"/>
<output message="s0:GetLastTradePriceOutput"/>
</operation>
</portType>
<binding name="StockQuoteSoapBinding" type="s0:StockQuotePortType">
<soap:binding style="document" transport= "http://
schemas.xmlsoap.org/soap/http"/>
<operation name="GetLastTradePrice">
<soap:eek:peration soapAction= "http://myadvancedwebserviceURI/
GetLastTradePrice" style="document"/>
<input> <soap:body use="literal"/></input>
<output> <soap:body use="literal"/></output>
</operation>
</binding>

<service name="StockQuoteService">
<documentation>
My first service
</documentation>
<port name="StockQuotePort" binding= "s0:StockQuoteBinding">
<soap:address location="http://localhost/otherWebService/
stockquote.asmx"/>
</port>
</service>
</definitions>


Thanks again, I look forward for any help.

- md
 
Ad

Advertisements

T

Tiago Halm

Try changing
<port name="StockQuotePort" binding= "s0:StockQuoteBinding">
to
<port name="StockQuotePort" binding= "s0:StockQuoteSoapBinding">

Tiago Halm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top