Axis label format

8 posts, 0 answers
  1. Chandana
    Chandana avatar
    13 posts
    Member since:
    Apr 2011

    Posted 29 Jun 2011 Link to this post

    Hi,

    I want to divide my Y-Axis label values by a million.
    Setting the AutoRange property to true shows a "mil" beside the number.
    Ex: 200,000,000 is shown as 200 mil.

    But I want it to just show 200. If I set the AutoRange to false, what would the defaultlabelformat be?

    Thanks & Regards,
    Chandana
  2. Evgenia
    Admin
    Evgenia avatar
    1406 posts

    Posted 04 Jul 2011 Link to this post

    Hello Chandana,

    You can specify any Custom Numeric Format String to your Axis Labels. For your scenario - you can use the fact that using the "," custom specifier the number to be formatted is divided by 1000 for each comma and set the DefaultLabelFormat of the Axis to something like: "#VAL{0,,}".

    Greetings,
    Evgenia
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
  4. Janaki
    Janaki avatar
    5 posts
    Member since:
    Dec 2011

    Posted 07 Jun 2013 Link to this post

    Hi,

        im using rad chart in my project,

    Im binding the chart x and y axis value from database. i want to bind some datas dynamiclly with the y value

    For example 0 lt,5 lt,10 lt....and for something 0 kg,5 kg,10 kg like this i want in my y axis ...

    i am to get tis values from database but how to bind with the chart...

      Chart.DefaultView.ChartArea.AxisY.DefaultLabelFormat = string.Format("{0}", QuarterSeries.unit);
  5. Evgenia
    Admin
    Evgenia avatar
    1406 posts

    Posted 12 Jun 2013 Link to this post

    Hello Janaki,

     You can format the values along the y axis by using a standard IValueConverter. It will convert the default value, to whatever format/value suits your scenario best. You may find a sample demonstrating this approach in the following forum post.

    Regards,
    Evgenia
    Telerik

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  6. 闫 avatar
    4 posts
    Member since:
    Jan 2014

    Posted 12 Aug 2014 Link to this post

    当我在做windows phone 一个图标上显示多条数据时,如何后台绑定数据。
    横坐标能不能按时间自动增长,图表中的数据按照时间的顺序自动填充进去,
    比如时间10:28能不能再横坐标上重复出现,如何使相同的横坐标不会自动合并
  7. Martin
    Admin
    Martin avatar
    1099 posts

    Posted 13 Aug 2014 Link to this post

    Hi,

    I would ask you to post your question in English. This will help us to understand your requirement and assist you further.

    Regards,
    Martin
    Telerik
     
    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
     
  8. Sumeet
    Sumeet avatar
    1 posts
    Member since:
    Sep 2014

    Posted 19 Sep 2014 in reply to Evgenia Link to this post

    Hello Evgenia,

    I used you example "#VAL{0,,}". But in the graph y axis show up like #val{0,,} screenshot is attached. I am using following code:

    valueAxis: {
                        labels: {format: "#val{0,,}"},
                        line: {visible: true}
                    },

    Am I doing something wrong?

    i need to get 1000000 to 1M
    2000000 to 2M and so on
  9. Martin
    Admin
    Martin avatar
    1099 posts

    Posted 23 Sep 2014 Link to this post

    Hello Summet,

    I noticed that your question is related to the Kendo UI chart. This is the Silverlight forum and this thread is related to the RadChart for Silverlight. Can you please post your question in new thread in the Kendo forum.

    However, keep in mind that there is no default format string for such formatting. Instead you can consider using label template.

    Regards,
    Martin
    Telerik
     
    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
     
Back to Top
DevCraft banner