I have a two part question concerning Android. The first, is if I have an xml file which comes prepackaged with the Android app containing modular data, where in the app should I host it? I’ve seen references to the assets folder, and I’ve seen references to res/xml. This xml file won’t be modified in and of itself, its read only, but it WILL be encrypted when its packaged, so will have to be decrypted by the app.
The second part of the question is, once I have the xml in the directory it will live in, how do I open it and parse its contents into a list view? The goal is to have the listviews sort of generate from the nodes of the xml. Meaning, the root node would generate the first options in the list view. As you click on the items corresponding with the nodes, a new listview will be generated based on what that subnode contains. Its basically using listviews to browse through an xml file.
Thanks for your help! I am sort of new to Android and Java so please don’t assume I know that much 🙂
1 Answer