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. Image for the cookie policy date

Placing an annotation below a series.


I would like to place an annotation below a series in a chart. Setting the Canvas.ZIndex of the annotation in concert with that of the series seems to have no effect. I suppose I could implement the annotation (a HorizontalLineAnnotation in this case) with a new series and arrange them that way, but am hoping a nicer solution is possible. Any suggestions?


Tim Rawlinson

1 Reply

DA Devi Aruna Maharasi Murugan Syncfusion Team September 14, 2016 07:37 AM UTC

Hi Tim, 
Thanks for contacting Syncfusion Support. 
We can achieve your requirement by overriding the OnApplyTemplate in SfChart class. Please find the code snippet below, 
protected override  void OnApplyTemplate() 
      // Canvas.ZIndexProperty is set to SeriesAnnotationCanvas 
      (GetTemplateChild("Part_SeriesAnnotationCanvas") as     
                               Canvas).SetValue(Canvas.ZIndexProperty, -1); 
We have prepared a demo sample for your reference and it can be downloaded from below link, 

Live Chat Icon For mobile
Up arrow icon