Axis labels not readable

Thread is closed for posting
4 posts, 0 answers
  1. Jaakko Hänninen
    Jaakko Hänninen avatar
    11 posts
    Member since:
    Jun 2009

    Posted 28 Sep 2009 Link to this post

    I have a problem that after run time modification labels at YAxis are not readable. I`m trying to convert time format from minutes to hour:minutes format at run time. It seems that these new labels doen`s fit to the area and result is mess. Timeformat is changed at PrePaint event handler. Control doesn`t update it`s measures after that.

    protected void MyChart_PrePaint(object sender, EventArgs e)
                RadChart are = (RadChart)sender;
                ChartYAxis yAxis = are.PlotArea.YAxis;

                are.Series[0].Appearance.LabelAppearance.Dimensions.AutoSize = false;
                are.Series[0].Appearance.LabelAppearance.Dimensions.Width = 500;          

                yAxis.Appearance.TextAppearance.AutoTextWrap = AutoTextWrap.False;
                yAxis.Appearance.TextAppearance.Dimensions.Width = 500;
                yAxis.Appearance.TextAppearance.Dimensions.AutoSize = false;

                foreach (ChartAxisItem axisItem in yAxis.Items)
                    axisItem.TextBlock.Text = "some text here";

  2. Schlurk
    Schlurk avatar
    812 posts
    Member since:
    May 2009

    Posted 28 Sep 2009 Link to this post

    If they do not fit have you tried to either change the angle of the labels, or the margins of the chart image? This could provide you with some more space for the labels.

    RadChart1.PlotArea.XAxis.Appearance.LabelAppearance.RotationAngle = -90; 

    RadChart1.PlotArea.Appearance.Dimensions.Margins.Right = 50; 
    RadChart1.PlotArea.Appearance.Dimensions.Margins.Left = 50; 

  3. DevCraft R3 2016 release webinar banner
  4. Ves
    Ves avatar
    2870 posts

    Posted 01 Oct 2009 Link to this post

    Hi guys,

    I would suggest checking the Auto Layout feature. All you need is one property - RadChart.AutoLayout = true.

    Best regards,
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  5. Jaseem
    Jaseem avatar
    4 posts
    Member since:
    Aug 2013

    Posted 20 Aug 2013 Link to this post


    i am RadChart display data as vertical bars. but axis labels are overlapping . i have searched a lot and found that
    RadChart.AutoTextWrap property can solve my issue . but i cannot find that property or even RadChart.AutoLayout property.
    iam using 2012 version of telerik . please help as soon as possible,

    thanks in advance

Back to Top