我有一個.net Web應用程序,該Web應用程序在頁面中嵌入了一個Flex應用程序。這個flex應用程序調用.net webservice。我可以通過調試跟蹤執行proccess,直到我得到的迴應都看起來不錯:SoapException:在從Flex調用.NET Web服務時缺失根元素
soap:ReceiverSystem.Web.Services.Protocols.SoapException: Server was unable to process request
. ---> System.Xml.XmlException: Root element is missing.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.ThrowWithoutLineInfo(String res)
at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlTextReader.Read()
at System.Web.Services.Protocols.SoapServerProtocol.SoapEnvelopeReader.Read()
at System.Xml.XmlReader.MoveToContent()
at System.Web.Services.Protocols.SoapServerProtocol.SoapEnvelopeReader.MoveToContent()
at System.Web.Services.Protocols.SoapServerProtocolHelper.GetRequestElement()
at System.Web.Services.Protocols.Soap12ServerProtocolHelper.RouteRequest()
at System.Web.Services.Protocols.SoapServerProtocol.RouteRequest(SoapServerMessage message)
at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest
request, HttpResponse response, Boolean& abortProcessing)
--- End of inner exception stack trace ---
從Flex中調用看起來不錯,通過web服務的執行是好的,但是這是我通過Wireshark的捕獲響應, 這裏發生了什麼?
我嘗試了好幾種Web方法,從「你好世界」 paramatized方法......所有復出相同的反應......
我認爲它可能是與編碼與「 - - & gt「,但我不確定如何控制.net渲染作爲響應。
如果請求格式錯誤,我不認爲我會看到正常執行通過web服務與調試器...我會嗎? – mmattax 2008-08-19 12:32:58