locked
Web service return NULL RRS feed

  • Question

  • OS: Vista
    IIS 7.0 in localhost
    VS 2005 3.5
    MS-sql 2008 express
    using web service

    in the application when I breakpoint and examine the return value,
    however, if i run it without debug, it return null. Can someone explain why this might be occuring?


    for exmaple:
    when i debug it result will be follwing:

      <?xml version="1.0" encoding="utf-8" ?>
    - <DataSet xmlns="http://localhost/WebMethod/Service.asmx">
    - <xs:schema id="NewDataSet" xmlns="" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
    - <xs:element name="NewDataSet" msdata:IsDataSet="true" msdata:UseCurrentLocale="true">
    - <xs:complexType>
    - <xs:choice minOccurs="0" maxOccurs="unbounded">
    - <xs:element name="DB">
    - <xs:complexType>
    - <xs:sequence>
      <xs:element name="PersonID" type="xs:int" minOccurs="0" />
      <xs:element name="LoginName" type="xs:string" minOccurs="0" />
      <xs:element name="Password" type="xs:string" minOccurs="0" />
      <xs:element name="FirstName" type="xs:string" minOccurs="0" />
      <xs:element name="LastName" type="xs:string" minOccurs="0" />
      </xs:sequence>
      </xs:complexType>
      </xs:element>
      </xs:choice>
      </xs:complexType>
      </xs:element>
      </xs:schema>
    - <diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1">
    - <NewDataSet xmlns="">
    - <DB diffgr:id="DB1" msdata:rowOrder="0">
      <PersonID>xx</PersonID>
      <LoginName>xxx</LoginName>
      <Password>xxxx</Password>
      <FirstName>xxx</FirstName>
      <LastName>xxx</LastName>
      </DB>
    - <DB diffgr:id="DB2" msdata:rowOrder="1">
      <PersonID>xx</PersonID>
      <LoginName>xxx</LoginName>
      <Password>xxx</Password>
      <FirstName>xxxxx</FirstName>
      <LastName>xxxx</LastName>
      </DB>
    - <DB diffgr:id="DB3" msdata:rowOrder="2">
      <PersonID>xx</PersonID>
      <LoginName>xx</LoginName>
      <Password>xxxx</Password>
      <FirstName>xx</FirstName>
      <LastName>xxxxxxx</LastName>
        </NewDataSet>
      </diffgr:diffgram>
      </DataSet>

    however when i run it without debug
    :
      <?xml version="1.0" encoding="utf-8" ?>
    - <DataSet xmlns="http://localhost/WebMethod/Service.asmx">
    - <xs:schema id="NewDataSet" xmlns="" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
    - <xs:element name="NewDataSet" msdata:IsDataSet="true" msdata:UseCurrentLocale="true">
    - <xs:complexType>
      <xs:choice minOccurs="0" maxOccurs="unbounded" />
      </xs:complexType>
      </xs:element>
      </xs:schema>
      <diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1" />
      </DataSet>

    • Moved by Zhi-Xin Ye Friday, March 27, 2009 11:48 AM off topic (Moved from .NET Base Class Library to Off-Topic Posts (Do Not Post Here))
    Monday, March 23, 2009 5:17 AM

Answers