'text/html', but expected 'text/xml'
|
| 'text/html', but expected 'text/xml' | I have written a PocketPC application that connects to a web service, and when im connected via the cable or via wireless then it pulls back the data correctly.
However when connected to GPRS, i get the following error
"Server found request content type to be 'text/html', but expected 'text/xml'"
Does anyone know why this is happening?
Someone previously suggested that its because it is returning too much data, but i have tested it just returning one 4 character string, and it still didnt work.
Any suggestions would be much appreciated!! -- Mark
| | ok that makes sense, however the error only happens when doing it over GPRS, so how can i simulate that?
-- Mark
"Altaf Al-Amin Najwani" wrote:
> Usually this sort of error comes when there some exception occured. I would > suggest you to debug ur web service using some simulator. Lets see below error > > An unhandled exception of type 'System.InvalidOperationException' occurred > in system.web.services.dll Additional information: Client found response > content type of 'text/html', but expected 'text/xml' > I would suggest you to open tracing on web application and see results. This > will give you an insight that what exactly is going on. Further more, ASP.Net > sometimes tries to return errors occuring in web methods as HTML page rather > than soap exception. > Thsi error occured in webservice but on ur pocket pc it will appear as > expected 'text/xml' error. > "Mark" wrote: > > I have written a PocketPC application that connects to a web service, and > > when im connected via the cable or via wireless then it pulls back the data > > correctly. > > > > However when connected to GPRS, i get the following error > > "Server found request content type to be 'text/html', but expected 'text/xml'" > > Does anyone know why this is happening? > > Someone previously suggested that its because it is returning too much data, > > but i have tested it just returning one 4 character string, and it still > > didnt work. > > Any suggestions would be much appreciated!! > > -- > > Mark
| | Mark wrote:
> "Server found request content type to be 'text/html', but expected > 'text/xml'" > > Does anyone know why this is happening? > Someone previously suggested that its because it is returning too > much data, but i have tested it just returning one 4 character > string, and it still didnt work. > Any suggestions would be much appreciated!!
Do you want to check the request to see what's sent? You can use the TraceExtension as given here: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/h tml/frlrfsystemwebservicesprotocolssoapextensionclasstopic.asp
-- Deepak Shenoy http://shenoyatwork.blogspot.com
| | I have had a little play around, and ive found that with Windows Authentication switched on, it doesnt work via GPRS, if i turn Win Authentication off, then it works fine.
So does Windows Authentication wrap it in larger packets or something that could be causing the problems?
-- Mark
"Deepak Shenoy" wrote:
> Mark wrote: > > > "Server found request content type to be 'text/html', but expected > > 'text/xml'" > > > > Does anyone know why this is happening? > > Someone previously suggested that its because it is returning too > > much data, but i have tested it just returning one 4 character > > string, and it still didnt work. > > Any suggestions would be much appreciated!! > Do you want to check the request to see what's sent? You can use the > TraceExtension as given here: > http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/h > tml/frlrfsystemwebservicesprotocolssoapextensionclasstopic.asp > -- > Deepak Shenoy > http://shenoyatwork.blogspot.com
|
|
|
|
|
 | Members Area | |
|
 | Last Web Marketing |
|
|
|
|
 | Last Programming Tips |
|
|
|
|
 | Last News |
|
|
|
|
|
|