Flexchart annotations

Posted by: cwilson on 30 June 2022, 7:12 am EST

    • Post Options:
    • Link

    Posted 30 June 2022, 7:12 am EST

    I am converting from a prior version C1Chart to FlexChart and trying to make it look the same. I cannot see how to rotate annotations. If not available, are there any workarounds?

  • Posted 30 June 2022, 10:53 pm EST

    Hi Wilson,

    We are sorry to inform you that currently it is not possible to rotate the annotations of FlexChart.

    However, we have raised an enhancement request to the development team regarding this feature. We will inform you once we have any update from the development team.

    [Internal Tracking Id - C1CHART-2092]

    Best Regards,

    Nitin

  • Posted 11 July 2022, 1:17 am EST

    Hi Wilson,

    Could you please provide a snapshot for your requirement. That what you want to achieve?

    Do you want to Rotate Annotations or DataLabels? In some cases, DataLabels can be used instead Annotations.

    If that’s the case then you can rotate DataLabel, for e.g. :

    
    flexChart.DataLabel.Angle = 45.
    
    

    Please refer the attached sample for the same: DataLabelDemo.zip

    Best Regards,

    Nitin

  • Posted 30 August 2022, 3:31 am EST - Updated 3 October 2022, 1:14 pm EST

    Here is an example:

  • Posted 30 August 2022, 10:36 pm EST

    Hi Chris,

    We are discussing this requirement with the development team.

    However, you can do a workaround for the same, by rendering rotated string over chart at a position. For that you need to handle Rendering event of FlexChart as:

    
        Private Sub FlexChart1_Rendering(ByVal sender As Object, ByVal e As RenderEventArgs)
            e.Engine.SetStroke(Brushes.Black)
            e.Engine.SetFont(New Font("Segoe UI", 9))
            Dim x = FlexChart1.AxisX.Convert(1) + 10
            Dim y = FlexChart1.AxisY.Convert((CType(FlexChart1.AxisY, C1.Chart.IAxis)).GetMin()) - 10
            Dim angle = 90
    
            'Annotation 1
            e.Engine.DrawStringRotated("Annotation 1", New C1.Chart._Point(x, y), New C1.Chart._Point(x, y), angle)
    
            'Annotation 2
            x = FlexChart1.AxisX.Convert(5) + 10
            e.Engine.DrawStringRotated("Annotation 2", New C1.Chart._Point(x, y), New C1.Chart._Point(x, y), angle)
    
            'Annotation 3
            x = FlexChart1.AxisX.Convert(8) + 10
            e.Engine.DrawStringRotated("Annotation 3", New C1.Chart._Point(x, y), New C1.Chart._Point(x, y), angle)
        End Sub
    
    

    Please refer the attached sample for the same : AnnotationTextRotation.zip

    Best Regards,

    Nitin

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels