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

XML4J parser classpath question

 
Howard Ralston
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,
I have downloaded XML4J into a folder named XMLzip. I then unzipped it into the folder according to the instrucions.Then I set my classpath to include e:\XMLzip\org\apache\xerces;
My program does not compile, giving error saying that DOMParser is not recognized.
Does anyone have any ideas about this? It seems to be the correct classpath, but I am not sure. What else could I try?
Thanks,
Howard
 
Howard Ralston
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone help me here?
 
Ajith Kallambella
Sheriff
Posts: 5782
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try copying the jar file to %JAVAROOT%\JRE\lib\ext directory. If that doesn't help, can you post the exact error message?
------------------
Ajith Kallambella M.
Sun Certified Programmer for the Java�2 Platform.
IBM Certified Developer - XML and Related Technologies, V1.
 
Howard Ralston
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Ajith,
I tried your advice and it worked fine with Apache's Xerces,
but when I tried the XML4J Xerces, I still got the error saying that class DOMParser was not found. I can use the Apache version, but I wanted to use XML4J because my book has a good listing of its methods. As I understand, most of the methods used for XML4J are the same as those used in the Apache version, but there are some differences. What is your experience in this? Which parser do you prefer, XML4J, JAXP, or Apache's Xerces?
Thanks,
Howard
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic