bar chart bar alignment issue

Thread is closed for posting
4 posts, 0 answers
  1. Rob
    Rob avatar
    14 posts
    Member since:
    Jun 2008

    Posted 09 Jul 2008 Link to this post

    Hi there,

    I'm having an issue getting the bars aligned with XAxix.Items.TextBlock.Text (xaxis label). 

    I have tried various versions of the following without any luck.

    PlotArea.XAxis.Appearance.LabelAppearance.Position.AlignedPosition = Telerik.Charting.Styles.

    AlignedPositions.TopRight;

    Any insight is appreciated.

    I'm using the latest RadChart control.

    thanks,
    Rob

  2. Ves
    Admin
    Ves avatar
    2926 posts

    Posted 10 Jul 2008 Link to this post

    Hi Rob,

    I am not really sure about this part "getting the bars aligned".

    This line
    PlotArea.XAxis.Appearance.LabelAppearance.Position.AlignedPosition = Telerik.Charting.Styles.AlignedPositions.TopRight;

    will affect the positioning of X axis item labels.

    For the bar labels you can use this code:
    RadChart1.Series[0].Appearance.LabelAppearance.LabelLocation = StyleSeriesItemLabel.ItemLabelLocation.Inside;
    RadChart1.Series[0].Appearance.LabelAppearance.Position.AlignedPosition = Telerik.Charting.Styles.AlignedPositions.TopRight;

    Hope this helps.

    Sincerely,
    Ves
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Rob
    Rob avatar
    14 posts
    Member since:
    Jun 2008

    Posted 10 Jul 2008 Link to this post

    Thanks for the reply Ves.  Sorry for the confusion.

    What I mean by "getting the bars aligned" is that the bars aren't lining up with item labels.  So you have a bar for day 3 but it's not above day 3 it's between day 2 and 3. 

    Not sure it it matters that I'm adding the item labels dynamically by date range.  This specific example is from May 25 - June 25.

    I tried:
    PlotArea.XAxis.Appearance.LabelAppearance.Position.AlignedPosition = Telerik.Charting.Styles.AlignedPositions.TopRight;

    and TopLeft, center etc..

    without any luck.  Any other suggestions?

    Thanks,
    Rob


  4. Ves
    Admin
    Ves avatar
    2926 posts

    Posted 10 Jul 2008 Link to this post

    Hi Rob,

    You can control this through XAxis.LayoutMode property. You can find more details here.

    Regards,
    Ves
    the Telerik team

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