Rounding off axis range

2 posts, 0 answers
  1. Fahad
    Fahad avatar
    17 posts
    Member since:
    May 2011

    Posted 24 Aug 2011 Link to this post


    I have a list of objects that has MaxValue = 680334468, MinValue = -680334468, I need to set a custom range on my axis to show rounded off value. Right now my axis is shown like this,

    I have a step value of 27213378 (MaxValue / (half of objects list)). I tried to round off the axis as,

    max = ceil( maxValue / 500000 ) * 500000
    min = ceil( minValue / 500000 ) * 500000
    step = 500000

    I'm assuming the chart will render if the axis is bigger than the data, and it gives me this axis results as,

    I would like to know how to round-off my cusotm axis range to  properly visualize it. Please let me know any sample / code to do this.

  2. Nikolay
    Nikolay avatar
    395 posts

    Posted 29 Aug 2011 Link to this post

    Hi Fahad,

    Indeed there is an issue when rounding off such large numbers and the axis range may not be properly calculated in scenarios like this one. The issue has been logged for our developers to investigate further and provide a fix for one of the upcoming versions of the control.

    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Back to Top