This is a migrated thread and some comments may be shown as answers.

Add series items on client with javascript

1 Answer 44 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
TonyG
Top achievements
Rank 1
TonyG asked on 12 Sep 2010, 10:19 PM
I've seen a couple postings here with people trying to get nice dynamic chart updates:
http://www.telerik.com/community/forums/aspnet-ajax/chart/real-time-and-auto-refresh-chart.aspx
http://www.telerik.com/community/forums/aspnet-ajax/chart/chart-blinks-on-ajax-refresh.aspx

I'm wondering if anyone has tried to dynamically update a RadChart entirely with Javascript on the client, without polling to the server. This would involve doing something like this:

function addPoint(data) {
  var chart = $find("<%=RadChart1.ClientID%>");
  chart.get_series(1).add(data);
}

A server-side push mechanism can then be used, where the client callback executes that function.  To make the chart appear to move through realtime the function can remove the first item in the series before adding the new data to the back-end.

I think the answer to this is might be that all of the rendering for RadChart is done on the server, with an image rendered to the client.  If that's the case - uhhhh, never mind.  :)   Seriously, maybe there is a way to manage this...?

Thanks!

1 Answer, 1 is accepted

Sort by
0
Yavor
Telerik team
answered on 15 Sep 2010, 08:37 AM
Hi TonyG,

At present, refreshing any data on the chart would require going to the server, changing the data to which the control is bound, and rebinding the chart. There is no option to handle this on the client.
I hope this information helps.

Greetings,
Yavor
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Chart (Obsolete)
Asked by
TonyG
Top achievements
Rank 1
Answers by
Yavor
Telerik team
Share this question
or