+ Start a Discussion

Webservice returns error

The error is below. I created the webservice in .net and then generated the apex class from the wsdl.

System.CalloutException: Web service callout failed: Unexpected element. Parser was expecting element 'http://schemas.xmlsoap.org/soap/envelope/:Envelope' but found ':html'

Class.NalpeironUpdateSeat.Service1Soap.seatUpdate: line 19, column 13
Class.orderExt.UpdateKeyActivationsWithNalpeiron: line 102, column 48
Class.orderExt.save: line 190, column 12
External entry point

The error is telling you the server returned an HTML response instead of SOAP, this might be because its actually a HTML response from a firewall or proxy blocking the request, or because there was an unhandled exception in your service (many soap toolkits can end up returning html in this case instead of a soap fault)