This following code generates a ClassNotFoundException, but only from an applet, and only on line 10. This seems to imply that the search path for classes given as a string in the argument of CreateXMLReader is different from the search path for classes instaniated in the method.

Can somebody tell me how to put "org.apache.xerces.parsers.SAXParser" in the appropriate search path for the CreateXMLReader method?

Thanks,




1 public String xpath(String xml, String xpath) {
2 String result = "";
3 SAXSource xmlsrc=new SAXSource(new InputSource(new StringReader(xml)));
4 XMLReader newRead = null;
5 org.apache.xerces.parsers.SAXParser Monkey=new
6 org.apache.xerces.parsers.SAXParser();
7 System.out.println(Monkey.getClass());
8 try{
9 newRead=
10 XMLReaderFactory.createXMLReader("org.apache.xerces.parsers.SAXParser");
11 }
12 catch (Exception e){
13 e.printStackTrace(System.err);
14 return (null);
15 }



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to