PDA

View Full Version : Change Chart Series on the fly



siggi
4 Jan 2013, 2:07 AM
Hello, and a happy new year everyone!

Is there a way to change the chart series on the fly?

What I am trying to achieve is:

User clicks on Radiogroup item => Chart Series changes from Column to Line and vice versa.

Thank you in advance for your help.

Siggi

mitchellsimoens
7 Jan 2013, 10:35 AM
Destroy the chart and create a new one will do it. You can try setting the series and executing redraw on the chart but I haven't ever had much luck with that.

siggi
8 Jan 2013, 3:46 AM
Thank you for your answer, Mitchell.

I now just create two charts (line & column) and show/hide on demand.

But I've got another question (or maybe another two - six ones :P):

1.) how can I change the colours of a grouped column chart?


2.) how can I change the colours, orientation, etc of the label of a grouped column chart series? I tried it like this:


label:{ display:'over',
color:'#FFFFFF',
field:['BookingsPrev','Bookings']
},

which shows the values of the grouped columns, but does not alter the color or position of the text.

Thank you in advance for your help.

alex9311
9 Jan 2013, 3:46 PM
I've been working on changing chart series on the fly as well. Having to redraw the whole chart each time seems inefficient but thats the best (and only) solution I've come accross