Reading and Writing XML file

南楼画角 提交于 2019-12-06 01:59:35

问题


I have an Application in which first I want to create a backup of message from inbox and store it into backup.xml file which is stored at SDCARD/MYBACKUP/mybackup.xml

Now I want to retrieve data, stored on SDCARD/MYBACKUP/mybackup.xml and display all messages in listview.


回答1:


For Writing XML file to sdcard see this answeer Qberticus's Answer

android Reading file is just simple you have to use Xml parsing See This for XML parsing

To R/W Sdcard You have to give Permission

   <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>


来源:https://stackoverflow.com/questions/9256245/reading-and-writing-xml-file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!