• Post Reply Bookmark Topic Watch Topic
  • New Topic

read xml file  RSS feed

 
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
If I have an XML-file that looks (for example) like this:
<data>
<name>Henk</name>
<gender>Male</gender>
</data>
How can I read in the name (Henk) into a String?
Any examples?

Thanks
 
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here are two articles that include sample code for parsing XML on J2ME with kXML:
Parsing XML in J2ME
XML and Java Language Programming for Wireless Devices
 
I'm THIS CLOSE to ruling the world! Right after reading this tiny ad:
ScroogeXHTML 7.1 - RTF to HTML5 / XHTML converter
https://coderanch.com/t/690611/ScroogeXHTML-RTF-HTML-XHTML-converter
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!