I have a XML file that I need to parse in the Android SDK.
How can I read the XML file path from resources?
The XML contains:
<Book>
<Chapter>
<NO> 1 </NO>
<Text> My Lord </Text>
</Chapter>
<Chapter>
<NO> 1 </NO>
<Text> My Lord </Text>
</Chapter>
</Book>
Put it under
your_project_root\res\xml\folder. Then you can open it with:There is an example on how to use
XmlResourceParserhere:http://android-er.blogspot.com/2010/04/read-xml-resources-in-android-using.html