jcommon-1.0.3 + jfreechart-0.9.20

A discussion forum for the JCommon class library.
Locked
fabiancho
Posts: 1
Joined: Sun Apr 23, 2006 5:16 pm

jcommon-1.0.3 + jfreechart-0.9.20

Post by fabiancho » Sun Apr 23, 2006 5:30 pm

I proved several examples and all have this error

Exception in thread "main" java.lang.NoClassDefFoundError: org/jfree/ui/Spacer
at org.jfree.chart.StandardLegend.<clinit>(StandardLegend.java:108)
at org.jfree.chart.Legend.createInstance(Legend.java:151)
at org.jfree.chart.JFreeChart.<init>(JFreeChart.java:319)
at org.jfree.chart.ChartFactory.createPieChart(ChartFactory.java:218)
at bd.First.main("myClass".java:20)

HELP ME!!!

Taqua
JFreeReport Project Leader
Posts: 698
Joined: Fri Mar 14, 2003 3:34 pm
Contact:

Post by Taqua » Sun Apr 23, 2006 7:22 pm

Hi,

it is near to impossible to use a newer version of JCommon as a replacement for a pre-1.0.0 JCommon version. At that time, the API of JCommon was not frozen, so refactorings and other changes usually made the new library version incompatible with the older one.

Either upgrade your JFreeChart to 1.0.0 to use the new JCommon version or use the JCommon version that has been supplied with JFreeChart at that time.

Regards,
Thomas

Locked