You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by Suresh Babu Koya <sk...@quark.co.in> on 2002/08/07 09:08:31 UTC
Unable to read XSL file
Hello group,
I tried to do a simple transformation of XML using a xsl file having #
character.
The parser had thrown a Exception that It could not read the file.
Is this a known problem. Is there any documentation for this kind of
characters that could create problems.
--Suresh
<Code>
// Cast the TransformerFactory.
SAXTransformerFactory saxTFactory = ((SAXTransformerFactory)
tFactory);
// Create a ContentHandler to handle parsing of the stylesheet.
TemplatesHandler templatesHandler = saxTFactory.newTemplatesHandler();
// Create an XMLReader and set its ContentHandler.
XMLReader reader = XMLReaderFactory.createXMLReader();
reader.setContentHandler(templatesHandler);
// Parse the stylesheet.
//****Problem comes in this parse method**********
reader.parse("D:/work/Test Cases/parameters/Test Map#.xsl");
//********************************
//Get the Templates object from the ContentHandler.
</Code>
<Exception>
org.xml.sax.SAXParseException: File "file:///D:/work/Test
Cases/parameters/Test Map#.xsl" not found.
at org.apache.xerces.framework.XMLParser.reportError(XMLParser.java:1202)
at
org.apache.xerces.readers.DefaultEntityHandler.startReadingFromDocument(Defa
ultEntityHandler.java:512)
at org.apache.xerces.framework.XMLParser.parseSomeSetup(XMLParser.java:312)
at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1080)
at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1122)
at sax2saxtest.SAX2SAX.main(SAX2SAX.java:70)
Exception in thread "main"
</Exception>
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org