Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Parsing an XMl file using apache xerces parser

 
satish satish
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When i try to parse An xml file i get following error .
Exception in thread "main" java.lang.NullPointerException
at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1094)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
My Code goes something like this
InputSource is = new InputSource(new FileReader (arrGDCFolders[i] + DIR_DAT+arrGDCFiles[k]));
parser.parse(is , new UploadController().new MtnSAXParserHandler());
 
Gergely Dombi
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
pls post the line no 1094 to see what throws the
NPE
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic