I am referring to the bar chart component since it has a property called Series Colors. The classic chart doesn’t expose the series colors as a property. You can use the following code for your classic chart:from java.awt import Color
colors = [Color.green, Color.yellow, Color.red, Color.blue, Color.orange, Color.magenta, Color.gray]
chart = event.source.parent.getComponent('Chart')
chart.getDynamicProps().get("Data").getRenderer().setSeriesColors(colors)
chart.createChart()
Just replace the “Data” with your dataset you want to change the series colors on.
1 Like