We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Are there any OnLoad/OnAnimationDone events that can be bound to?

Thread ID:

Created:

Updated:

Platform:

Replies:

132980 Oct 2,2017 01:02 PM Oct 3,2017 06:54 AM Xamarin.iOS 1
loading
Tags: SfChart
Jeremy Iamurri
Asked On October 2, 2017 01:02 PM

I'd like to react to some charts finishing their animations with either an event or a callback.

Is there anything like this already available in Syncfusion for Xamarin.iOS?

Parthiban Sundaram [Syncfusion]
Replied On October 3, 2017 06:54 AM

Hi Jeremy, 
 
Thanks for using Syncfusion products. 
 
You can achieve this requirement by inheriting chart segment class and overriding the AnimationStopped method. Please refer the following code snippet for more details. 
 
Code Snippet: 
 
 
    public class ColumnSegmentExt : SFColumnSegment 
    { 
 
         //This method will call for every segment creation 
                         
        public override void AnimationStopped(CoreAnimation.CAAnimation anim, bool finished) 
        { 
            if(Series.Segments.Last() == this) // condition for animation end 
            { 
              //do your stuff 
            } 
 
            base.AnimationStopped(anim, finished); // Must call base to avoid the memory leak 
        } 
    } 
 
 
To render the inherited segment to series. 
 
 
    public class ColumnSeriesExt : SFColumnSeries 
    { 
        protected override SFChartSegment CreateSegment() 
        { 
            return new ColumnSegmentExt(); 
        } 
    } 
 
Please download the sample from following location. 
 
 
Please let us know, if you need further assistance on this.  
 
Regards, 
Parthiban S  


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;