Issue Question:
Using HTML5 charts in JasperReports version 5.x., how do I color my chart series based upon the values in my dataset without ordering my query? For example, an answer of "no" should be RED, "yes" should be green, like:
Resolution:
You can set series color as an axis level property, then in the Advanced Properties of your measure, add a Series Property Contributor with the name "color", which is the highcharts series property name, and specify a bucket property value of [axis level name].[property name].
See the attached example, hc_series_color.jrxml, suitable for version 5.1 or higher, and reference our sample "foodmart" database as your datasource.
Ref. Case #00034523
Recommended Comments
There are no comments to display.