RE: [xsl] Problem transforming a xml document

Subject: RE: [xsl] Problem transforming a xml document
From: Cams Ismael <Ismael.Cams@xxxxxxxxxxx>
Date: Fri, 14 Mar 2003 14:33:06 +0100
Check if the jar file that contains the
"org.apache.xerces.parsers.SAXParser" class is on your classpath.

Kind regards,

-----Original Message-----
From: Carlos Barroso [mailto:est-c-barroso@xxxxxxxxxxxxx]
Sent: vrijdag 14 maart 2003 11:29
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: [xsl] Problem transforming a xml document


I'm having problems transforming a XML file. Here is the class
source code. It's only a few lines:

//---------------------- CODE -------------------------

// ** import's **

public class GenerateHTML {
  public String process(String xmlString, String xslFile) throws
TransformerConfigurationException, TransformerException, DocumentException,
SAXException {

    ByteArrayOutputStream result = new ByteArrayOutputStream();

    SAXReader reader = new SAXReader("org.apache.xerces.parsers.SAXParser");
    Document document = InputSource(new

    TransformerFactory factory = TransformerFactory.newInstance();
    Transformer transformer = factory.newTransformer(new StreamSource(new

    DocumentSource source = new DocumentSource(document);
    transformer.transform(source, new StreamResult(result));

//---------------------- END CODE -------------------------

I've tested the two parameters ("xmlString" and "xslFile") and they have the
information that I want.
I'm using this class inside a bean and every time I try to transform the
generated XML (which is valid! I tested it with XML Spy 5) it keeps giving
me the following error:

javax.xml.transform.TransformerFactoryConfigurationError: Provider null
could not be instantiated: java.lang.NullPointerException
	at javax.xml.transform.TransformerFactory.newInstance(Unknown
( ... )

I can't figure out what the problem is!? I've never had this problem before.

Can someone help me please.

 XSL-List info and archive:

 XSL-List info and archive:

Current Thread