86154

“org.xmlpull.v1.XmlPullParserException: expected: START_TAG”

Question:

I am developing an application which uses KSOAP2 with Android 2.0. I am getting this error:

<blockquote>

"org.xmlpull.v1.XmlPullParserException: expected: START_TAG"

</blockquote>

Can anyone tell me why this is happening?

Answer1:

Could you post the full error?

Look out for the following type of error as I received:

WARN/System.err(2330): org.xmlpull.v1.XmlPullParserException: expected: START_TAG {http://www.w3.org/2001/12/soap-envelope}Envelope (position:START_TAG

@1:4 in java.io.InputStreamReader@47ff3050)

The h1 tag is from 404 Not Found

so in my case, the webservice was down. Perhaps your webservice is rejecting your version 1.2 soap request with something equally unparsable

Answer2:

It's hard to say but the Exception might be due to malformed XML being passed to the Parser. It's possible that you're not initialising parser correctly and so it can't see any XML.

Can you <strong>edit</strong> your question add the code you have which uses the Parser.

Answer3:

i also got same error and i found 2 reasons behind it, first your URL is not correct second you are using wrong method name,,, recheck it and try...

Recommend

  • Add filename and length parameter to WCF stream when Transfermode = Stream
  • wsContext.getMessageContext().get(MessageContext.SERVLET_REQUEST) returns null on Jetty?
  • Testing custom SOAP Headers in ASMX
  • Cannot update firebase version [duplicate]
  • JsonMappingException: Can not deserialize instance of java.lang.Integer out of START_OBJECT token
  • jinja2 template not found and internal server error
  • help('modules') crashing? Not sure how to fix
  • Feature detection of foreignObject in SVG
  • XSD with multi occurrences unordered
  • Hibernate to update table schema
  • Floated image with variable width and heading with background image
  • Undefined references when compiling gSOAP client
  • Button text different than value submitted in query string
  • Odoo 10 - Overriding unlink method
  • Needing to do .toArray() to get output of mongodb .find() on key name not value
  • Jetty 9 HashLoginService
  • MongoError: Incorrect arguments
  • Read a local file using javascript
  • Jetty Server not starting: Unable to establish loopback connection
  • does jqgrid support a multiple checkbox list for editing
  • Optimizing database types to compact database (SQLite)
  • Obtain ObjectIdHex value from mgo query
  • Updating server-side rendering client-side
  • Cross-Platform Protobuf Serialization
  • Change an a tag attribute in JavaScript based on screen width
  • Timeout for blocking function call, i.e., how to stop waiting for user input after X seconds?
  • Do I've to free mysql result after storing it?
  • bootstrap to use multiple ng-app
  • How to get icons for entities from eclipse?
  • Windows forms listbox.selecteditem displaying “System.Data.DataRowView” instead of actual value
  • Proper folder structure for lots of source files
  • Proper way to use connect-multiparty with express.js?
  • Turn off referential integrity in Derby? is it possible?
  • How does Linux kernel interrupt the application?
  • LevelDB C iterator
  • JaxB to read class hierarchy
  • Observable and ngFor in Angular 2
  • How to Embed XSL into XML
  • UserPrincipal.Current returns apppool on IIS
  • Conditional In-Line CSS for IE and Others?