Getting an error while accessing Web Services from a Windows Client

  • Thread starter Ramesh Ramachandran
  • Start date
R

Ramesh Ramachandran

I have deployed the same web services in two machines.
I have used Microsoft Web services extensions.
The web service has a method Search.
When there is no return type defined for the method it works on both
the machines.
When a return type is defined for the method. It fails in one machine
but works fine in the other machine.
I am giving below the error message and stack trace.

The error message:
The XML declaration is unexpected. Line 11, position 191.

The StackTrace of the exception:
at System.Xml.XmlTextReader.ParseTag()
at System.Xml.XmlTextReader.ParseRoot()
at System.Xml.XmlTextReader.Read()
at Microsoft.Web.Services.XmlSkipDTDReader.Read()
at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc)
at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader,
Boolean preserveWhitespace)
at System.Xml.XmlDocument.Load(XmlReader reader)
at Microsoft.Web.Services.SoapEnvelope.Load(Stream stream)
at Microsoft.Web.Services.InputStream.GetRawContent()
at Microsoft.Web.Services.InputStream.get_Length()
at System.Xml.XmlScanner..ctor(TextReader reader, XmlNameTable ntable)
at System.Xml.XmlTextReader..ctor(String url, TextReader input,
XmlNameTable nt)
at System.Xml.XmlTextReader..ctor(TextReader input)
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage
message, WebResponse response, Stream responseStream, Boolean
asyncCall)
at System.Web.Services.Protocols.SoapHttp
ClientProtocol.Invoke(String methodName, Object[] parameters)
at TestHarness.User.User.Search():line 619
 

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

Members online

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top