How to right align vertical bars

3 posts, 0 answers
  1. Sam
    Sam avatar
    18 posts
    Member since:
    Nov 2012

    Posted 06 Dec 2012 Link to this post

    Edit:  I posted in the wrong forum, sorry.  I am using ChartView.

    1.) I have a barchart with vertical bars.  Data is added to my chart in the elapsed event of a timer.  When I add a new bar to the chart I want it placed on the right side.  As new bars are added, I want existing bars to be pushed to the left. How do I do this please? I tried setting HorizontalAlignment and HorizontalContentAlignment on both the BarSeries and the Horizontal axis but neither works.

    2.) I want to set the width of each bar.  I am using GapLength at the moment to make the bars narrower but it does not work as the number of bars added to the chart increases.  More specifically, I want to set the width of each bar and the space between them i.e. margin to some fixed amount and fill the chart from the right as described above.

    Thanks,
    Sam

  2. Petar Kirov
    Admin
    Petar Kirov avatar
    425 posts

    Posted 11 Dec 2012 Link to this post

    Hi Sam,

    1. I have attached a sample project demonstrating the behaviour you requested.

    2. The RadChartView does not support such a user defined sizing and positioning. The chart internally calculates the bar width depending on a number of factors such as the number of categories and the width of the chart.
     
    All the best,
    Petar Kirov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. UI for WPF is Visual Studio 2017 Ready
  4. Sam
    Sam avatar
    18 posts
    Member since:
    Nov 2012

    Posted 11 Dec 2012 Link to this post

    Thank you Petar, 
    I'm disapointed I cant set the bar width.  That seems like such a fundamental element that the user should be able to control.   
Back to Top