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

Animating charts

1 Answer 47 Views
Chart
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Dan-Sorin
Top achievements
Rank 1
Dan-Sorin asked on 21 Apr 2016, 11:10 AM

Hello guys,

So, we are trying to animate a Telerik bar series chart such that the bars scale (grow from 0 to their y-axis value in like 1 second time). Based on Telerik suggestion here (http://www.telerik.com/forums/plot-effect-and-animation), we have wrapped the bars into a custom border on which we actually do the animation. Basically, we animate the Y-axis of the border to scale from 0 to 1 in the given timespan and as it scales, the bars in the chart appear as animated (apparently, we had to do this in order to make the bars animate from bottom to top instead of the Telerik chart animating options, which make the bars grow from top to bottom).

However, we are running into the following issue. We are starting the animation on border loaded event (which seemed to be the only event which would actually trigger the animation). This results in our chart getting animated everytime the view is reloaded. However, we want the animation to run only on the first load and eventually on reload with updated data (like actually new data from the server). Because we are using the Border.Loaded event, we cannot control when to trigger the start of the animation. Do you have any suggestions on how to trigger the chart animation on a custom event (something we can actually control ourselves) ?

Thanks and curiously waiting for your reply,

Dan

1 Answer, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 26 Apr 2016, 07:07 AM
Hi Dan,

It seems the problem is not directly related to the chart itself, but rather on the app flow. The requirement to start animation on first load and on data reload has to be managed by your own code and not by the chart. Whether this will be an event or a method call is your decision, still in both cases the it's a matter of application logic.

Best regards,
Ves
Telerik
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 Feedback Portal and vote to affect the priority of the items
Tags
Chart
Asked by
Dan-Sorin
Top achievements
Rank 1
Answers by
Ves
Telerik team
Share this question
or