I am trying to create the following class using MS J++ 1.1 (I know it's
ancient) on a WIN2k SP3 machine
//
//
// Fop
//
//
import org.apache.fop.apps.Driver;
import org.apache.fop.apps.FOPException;
import org.apache.fop.apps.Version;
import org.apache.fop.apps.InputHandler;
import org.apache.fop.apps.XSLTInputHandler;
import org.apache.fop.layout.Page;
import org.apache.fop.messaging.MessageHandler;
import javax.xml.transform.*;
import org.xml.sax.*;
import java.io.*;
public class fop
{
public void xms2PDF(File xmlFile, File xslFile, String outFile) throws
TransformerConfigurationException, TransformerException,
FileNotFoundException, FOPException, IOException
{
Driver driver = new Driver();
Driver.setRenderer(Driver.RENDER_PDF);
InputHandler inputHandler = new XSLTInputHandler(xmlFile,
xslFile);
XMLReader parser = inputHandler.getParser();
Driver.setOutputStream(new FileOutputStream(outFile));
Driver.render(parser, inputHandler.getInputSource());
}
}
classpath of
C:\fop-0.20.4\build\fop.jar;C:\fop-0.20.4\LIB\avalon-framework-cvs-20020315.jar;C:\fop-0.20.4\LIB\xml-apis.jar
But get the following errors
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(6,8) : error J0049:
Undefined name 'org.apache.fop.apps.Driver'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(7,8) : error J0049:
Undefined name 'org.apache.fop.apps.FOPException'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(8,8) : error J0049:
Undefined name 'org.apache.fop.apps.Version'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(9,8) : error J0049:
Undefined name 'org.apache.fop.apps.InputHandler'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(10,8) : error J0049:
Undefined name 'org.apache.fop.apps.XSLTInputHandler'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(11,8) : error J0049:
Undefined name 'org.apache.fop.layout.Page'
C:\Program Files\DevStudio\MyProjects\Fop\Fop.java(12,8) : error J0049:
Undefined name 'org.apache.fop.messaging.MessageHandler'
Error executing jvc.exe.
Fop - 7 error(s), 0 warning(s)
Heeelp
Matthew Lancashire
IT Project Manager
Initial Electronic Security Ltd
Tel.: 01254 688555
FAX:01254 267552
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]