NoClassDefFoundError
807589Jan 14 2009 — edited Jan 14 2009I have installed BIRT for eclipse on Vista 64 and try to use the genReport.bat file that comes with the BIRT runtime engine (downloaded seperately). I do this:
genReport -p "dataSource=C:\temp\EmployeeData.xml" -f PDF -o report.pdf design.rptDesign
form cmd but get this error:
C:\birt-runtime-2_3_1\ReportEngine>ECHO off
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/birt/repo
rt/engine/api/ReportRunner
Caused by: java.lang.ClassNotFoundException: org.eclipse.birt.report.engine.api.
ReportRunner
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Could not find the main class: org.eclipse.birt.report.engine.api.ReportRunner.
Program will exit.
C:\birt-runtime-2_3_1\ReportEngine>
As I understand the reason is that it cannot find the class ReportRunner. This class is located in:
C:\birt-runtime-2_3_1\ReportEngine\lib\engineapi.jar
so I have defined a user variable (Advanced system->Environment Variables ) called 'classpath' with this value:
.;C:\birt-runtime-2_3_1\ReportEngine\lib\engineapi.jar;
I have also tried:
set CLASSPATH=.;C:\birt-runtime-2_3_1\ReportEngine\lib\engineapi.jar
but I still get the error.
Any hints are appreciated!