Configuring Axis Selection in Kendo Chart

2 posts, 0 answers
  1. Eric
    Eric avatar
    1 posts
    Member since:
    Nov 2014

    Posted 25 Oct 2016 Link to this post

    I'm implementing a Kendo bar chart representing power usage for 24 hours of a day. I'm following the demo from here.( ). Assuming the hour axis(x-axis) has 24 points and 24 data values, the start point being 12am and end point 12am next day (or 11:59:59pm same day), how to get value of the 25th axis point. The way chart represents data is, 24 bars placed between 25 axis points. In the above demo,if you select first single unit in x-axis it console logs `Select end :: 0 - 1 (1952 - 1952), Select start :: 0 - 1 (1952 - 1952)` , which is little confusing, How can start and end value be same? In my case, it is working fine till 24th axis point, but once i select 24th bar, the 25th axis point(the end point) logs out undefined. How to get around this? Any suggestions?


  2. Iliana Nikolova
    Iliana Nikolova avatar
    2622 posts

    Posted 27 Oct 2016 Link to this post

    Hi Eric,

    In the selectEnd event you could reach the axis categories as well as the selection range. Hence you could use custom JavaScript and display the actual selection range for each category except the last one. For the 25th axis point you could for example display only the from value. Take a look at the following dojo which demonstrates a possible implementation:

    Iliana Nikolova
    Telerik by Progress
    Build rich, delightful, *native* Angular 2 apps with Kendo UI for Angular 2. Try it out today! Kendo UI for Angular 2 (currently in beta) is a jQuery-free toolset, written in TypeScript, designed from the ground up to offer true, native Angular 2 components.
Back to Top