in reply to Perl web service consumed by c# client returns null.
Hi, Monks, Please don't get confused with two headers. first header you see is typed by me in the perl webservice to see what web service is returning. Line from Http is what web service seems returning, but c# client getting null value.
Thank you.Exception: System.InvalidOperationException: Client found response con +tent type of '', but expected 'text/xml'. The request failed with the error message: -- Content-Type : text/xml #I have added this line in the perl web servic +e like print "\nContent-type : text/xml\n\n" to check what exactly it + returns. #################################################################### HTTP/1.1 200 OK Content-Length: 1468 Content-Type: text/xml; charset=utf-8 SOAPServer: SOAP::Lite/Perl/1.17 <?xml version="1.0" encoding="UTF-8"?><soap:Envelope soap:encodingStyl +e="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soap="http://sche +mas.xmlsoap .org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/en +coding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http +://www.w3.o rg/2001/XMLSchema-instance"><soap:Body><MRWebServices__searchResponse +xmlns="MRWebServices"><return xsi:type="xsd:string"><data> <array> <item key="0"> <map> <item key="mrid">1</item> <item key="mrtitle">Test ticket for edit issue.</item> </map> </item> <item key="1"> <map> <item key="mrid">2</item> <item key="mrtitle">Test ticket for edit issue2.</item> </map> </item> <item key="2"> <map> <item key="mrid">3</item> <item key="mrtitle">Test ticket for edit issue3.</item> </map> </item> <item key="3"> <map> <item key="mrid">4</item> <item key="mrtitle">Test ticket for edit issue4.</item> </map> </item> <item key="4"> <map> <item key="mrid">5</item> <item key="mrtitle">Test ticket for edit issue5.</item> </map> </item> </array> </data> </return></MRWebServices__searchResponse></soap:Body></soap:Envelope> --. at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadRespons +e(SoapClientMessage message, WebResponse response, Stream responseStr +eam, Boolea n asyncCall) at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(Stri +ng methodName, Object[] parameters) at Search.MRWebServices__search(String usr, String pw, String extra +Info, String query) at main.Main()
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl web service consumed by c# client returns null.
by haj (Vicar) on Dec 13, 2019 at 09:52 UTC | |
by Anonymous Monk on Dec 13, 2019 at 09:58 UTC | |
by afoken (Chancellor) on Dec 13, 2019 at 10:17 UTC | |
by haj (Vicar) on Dec 13, 2019 at 10:36 UTC | |
by Anonymous Monk on Dec 13, 2019 at 11:03 UTC | |
by haj (Vicar) on Dec 13, 2019 at 12:26 UTC | |
|
Re^2: Perl web service consumed by c# client returns null.
by bliako (Abbot) on Dec 13, 2019 at 09:16 UTC |