Jump to content

Null 'dataset' exception when rendering charts


al_ryder

Recommended Posts

Hi,

I was wondering if there was a workaround for the fact that for some charts when the query associated with them returns null, the rendering of the chart dies. i.e.  I have a report with a Area Chart and the whole report dies because the chart sometimes get passed null data:

java.lang.IllegalArgumentException: Null 'dataset' argument. at org.jfree.data.general.DatasetUtilities.findStackedRangeBounds(DatasetUtilities.java:1364) at org.jfree.data.general.DatasetUtilities.findStackedRangeBounds(DatasetUtilities.java:1349) at org.jfree.chart.renderer.category.StackedAreaRenderer.findRangeBounds(StackedAreaRenderer.java:171) at org.jfree.chart.plot.CategoryPlot.getDataRange(CategoryPlot.java:3897) at org.jfree.chart.axis.NumberAxis.autoAdjustRange(NumberAxis.java:428) at org.jfree.chart.axis.NumberAxis.configure(NumberAxis.java:411) at org.jfree.chart.axis.Axis.setPlot(Axis.java:964) at org.jfree.chart.plot.CategoryPlot.(CategoryPlot.java:542) at org.jfree.chart.ChartFactory.createStackedAreaChart(ChartFactory.java:1185)

 

Thanks

Al

 



Post Edited by al_ryder at 05/20/2010 00:59
Link to comment
Share on other sites

  • 2 weeks later...
  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • 3 years later...

Hello I have same problem. My chart is placed on a group header band and yes, it uses a subdataset. In fact report has many subdatasets an many charts placed on group header bands. Please I welcome any advice, thanks.

 

EDIT: sorry my error. it works now. no error message

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...