Problem parsing .NET 2.0 web service response in client.

Discussion in 'ASP .Net Web Services' started by javaordotnet, Nov 13, 2006.

  1. javaordotnet

    javaordotnet Guest

    I am able to call to the .net 2.0 web service with my client and see it
    return from VS debugger. When the client returns from calling the .NET
    2.0 webservice, I get the error meesage:

    "First Element must contain the local name, Envelope"

    Does the asmx .NET web service NOT return the SOAP header? If I can get
    to the web service and executing find from my client, what is the web
    service sending back by default?

    Here is my WSDL:

    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    xmlns:tns="http://tempuri.org/"
    xmlns:s="http://www.w3.org/2001/XMLSchema"
    xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
    xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
    targetNamespace="http://tempuri.org/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
    <wsdl:types>
    <s:schema elementFormDefault="qualified"
    targetNamespace="http://tempuri.org/">
    <s:element name="Ping">
    <s:complexType />
    </s:element>
    <s:element name="PingResponse">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="PingResult"
    type="s:string" />
    </s:sequence>
    </s:complexType>
    </s:element>
    <s:element name="GetInventoryReport">
    <s:complexType />
    </s:element>
    <s:element name="GetInventoryReportResponse">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1"
    name="GetInventoryReportResult" type="tns:Results" />
    </s:sequence>
    </s:complexType>
    </s:element>
    <s:complexType name="Results">
    <s:sequence>
    <s:element minOccurs="1" maxOccurs="1" name="timestamp"
    type="s:dateTime" />
    <s:element minOccurs="0" maxOccurs="1" name="status"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="message"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="report"
    type="tns:ArrayOfInventoryReport" />
    </s:sequence>
    </s:complexType>
    <s:complexType name="ArrayOfInventoryReport">
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="unbounded"
    name="InventoryReport" nillable="true" type="tns:InventoryReport" />
    </s:sequence>
    </s:complexType>
    <s:complexType name="InventoryReport">
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="CONTRACT"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="PRODUCT_NAME"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="VOLUME_TYPE"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="MV_HEADER_DATE"
    type="s:string" />
    <s:element minOccurs="0" maxOccurs="1" name="TICKET"
    type="s:string" />
    <s:element minOccurs="1" maxOccurs="1" name="BARRELS"
    type="s:double" />
    <s:element minOccurs="1" maxOccurs="1" name="PRODUCT_ORDER"
    type="s:int" />
    <s:element minOccurs="1" maxOccurs="1" name="SORT_ORDER"
    type="s:int" />
    </s:sequence>
    </s:complexType>
    </s:schema>
    </wsdl:types>
    <wsdl:message name="PingSoapIn">
    <wsdl:part name="parameters" element="tns:Ping" />
    </wsdl:message>
    <wsdl:message name="PingSoapOut">
    <wsdl:part name="parameters" element="tns:PingResponse" />
    </wsdl:message>
    <wsdl:message name="GetInventoryReportSoapIn">
    <wsdl:part name="parameters" element="tns:GetInventoryReport" />
    </wsdl:message>
    <wsdl:message name="GetInventoryReportSoapOut">
    <wsdl:part name="parameters"
    element="tns:GetInventoryReportResponse" />
    </wsdl:message>
    <wsdl:portType name="InventoryServicesSoap">
    <wsdl:operation name="Ping">
    <wsdl:input message="tns:PingSoapIn" />
    <wsdl:output message="tns:PingSoapOut" />
    </wsdl:operation>
    <wsdl:operation name="GetInventoryReport">
    <wsdl:input message="tns:GetInventoryReportSoapIn" />
    <wsdl:output message="tns:GetInventoryReportSoapOut" />
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="InventoryServicesSoap"
    type="tns:InventoryServicesSoap">
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
    <wsdl:operation name="Ping">
    <soap:operation soapAction="http://tempuri.org/Ping"
    style="document" />
    <wsdl:input>
    <soap:body use="literal" />
    </wsdl:input>
    <wsdl:output>
    <soap:body use="literal" />
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="GetInventoryReport">
    <soap:operation
    soapAction="http://tempuri.org/GetInventoryReport" style="document" />
    <wsdl:input>
    <soap:body use="literal" />
    </wsdl:input>
    <wsdl:output>
    <soap:body use="literal" />
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:binding name="InventoryServicesSoap12"
    type="tns:InventoryServicesSoap">
    <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
    <wsdl:operation name="Ping">
    <soap12:operation soapAction="http://tempuri.org/Ping"
    style="document" />
    <wsdl:input>
    <soap12:body use="literal" />
    </wsdl:input>
    <wsdl:output>
    <soap12:body use="literal" />
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="GetInventoryReport">
    <soap12:operation
    soapAction="http://tempuri.org/GetInventoryReport" style="document" />
    <wsdl:input>
    <soap12:body use="literal" />
    </wsdl:input>
    <wsdl:output>
    <soap12:body use="literal" />
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="InventoryServices">
    <wsdl:port name="InventoryServicesSoap"
    binding="tns:InventoryServicesSoap">
    <soap:address
    location="http://localhost:2067/NGLPTOServices_VS/InventoryServices.asmx"/>
    </wsdl:port>
    <wsdl:port name="InventoryServicesSoap12"
    binding="tns:InventoryServicesSoap12">
    <soap12:address
    location="http://localhost:2067/NGLPTOServices_VS/InventoryServices.asmx"/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
    
    javaordotnet, Nov 13, 2006
    #1
    1. Advertising

  2. "javaordotnet" <> wrote in message
    news:...
    >I am able to call to the .net 2.0 web service with my client and see it
    > return from VS debugger. When the client returns from calling the .NET
    > 2.0 webservice, I get the error meesage:
    >
    > "First Element must contain the local name, Envelope"
    >
    > Does the asmx .NET web service NOT return the SOAP header? If I can get
    > to the web service and executing find from my client, what is the web
    > service sending back by default?


    Have you tried looking at the bits on the network?

    John
    John Saunders, Nov 14, 2006
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    206
  2. Felix Wafytech
    Replies:
    2
    Views:
    391
    Felix Wafytech
    Nov 24, 2006
  3. acssi
    Replies:
    0
    Views:
    330
    acssi
    Jan 16, 2007
  4. Curt K
    Replies:
    3
    Views:
    449
    John Saunders [MVP]
    Jun 15, 2007
  5. Leo Violette
    Replies:
    0
    Views:
    1,015
    Leo Violette
    Apr 17, 2009
Loading...

Share This Page