android - Parsing of XML file from internal storage of tablet using pull parser -


i using below code parse xml file internal storage using pull parser closes application forcrefully please suggest me..!

fileinputstream fis = getapplicationcontext().openfileinput("abc.xml");  xmlpullparserfactory factory = xmlpullparserfactory.newinstance();             factory.setnamespaceaware(true);             xpp = factory.newpullparser();             xpp.setinput(fis,null);  eventtype = xpp.geteventtype(); 

file "abc.xml" stored in internal memory of tablet unable parse it.. "abc.xml" file content same res/xml/abc.xml folder here parsing done successfully.

thank you.

use asynctask or run non ui thread.


Comments