position my chart axis item below the x axis programmatically

Thread is closed for posting
5 posts, 0 answers
  1. al
    al avatar
    77 posts
    Member since:
    Oct 2007

    Posted 03 Jun 2008 Link to this post

    Hello

    I want to position my chart axis item below the x axis programmatically. For short text its ok. How can it be done?
    Thank you.

     

     

  2. Ves
    Admin
    Ves avatar
    2926 posts

    Posted 04 Jun 2008 Link to this post

    Hello al,

    You can try setting RadChart1.AutoLayout to true as shown in this online example. You can also consider modifying the plot area margins and the x axis item labels rotation angle as shown in this online example. This would be done in code-behind like this:

    RadChart1.PlotArea.Appearance.Dimensions.Margins.Bottom = Telerik.Charting.Styles.Unit.Percentage(20);
    RadChart1.PlotArea.XAxis.Appearance.LabelAppearance.RotationAngle = 45;

    Hope this helps.

    Best wishes,
    Ves
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. al
    al avatar
    77 posts
    Member since:
    Oct 2007

    Posted 04 Jun 2008 Link to this post

    Thank you Ves,
    but it does not work. The text is across the x axis. When i wrap it, part of the text is not displayed. It worked in the 1.1 radchart without adding any properties.
    Is it possible for me to post you a picture of the chart?
  4. al
    al avatar
    77 posts
    Member since:
    Oct 2007

    Posted 05 Jun 2008 Link to this post

    i tried to increase the height of the block

    chartAxisItem.TextBlock.Appearance.Dimensions.Height=..

    But still is stays the same.
    If i increase the height of the chart, it is the plot area that gets larger, the space below the x-axis stays the same.

  5. Ves
    Admin
    Ves avatar
    2926 posts

    Posted 06 Jun 2008 Link to this post

    Hello al,

    Please, find attached a sample page with long X axis labels, wrapped and rotated. Hope this helps.

    Kind regards,
    Ves
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top