This is a migrated thread and some comments may be shown as answers.

Categoryaxis wont clear on reading an empty set of data

3 Answers 73 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Juuso
Top achievements
Rank 1
Juuso asked on 21 Jan 2013, 08:20 AM
I have a Columns Chart which shows all data on initial page load. User has the option to change the data query by selecting checkboxes which are read when the chart does datasource.read().
The problem is that if the data is empty the category axis is not emptied. Instead it just shows the previous axis without any data. Is there a way to for the chart to redraw category axis?

3 Answers, 1 is accepted

Sort by
0
Iliana Nikolova
Telerik team
answered on 22 Jan 2013, 12:10 PM
Hello Juuso,

The observed behavior (the category axis is not emptied) is due to a bug in the current version of Kendo UI Chart. We are working on the problem and will do our best to provide a fix as soon as possible. Please accept my apologies for the inconvenience caused. 

Meanwhile you can achieve the desired outcome as set an empty array to the categoryAxis. For example: 
var chart = $("#chart").data("kendoChart");
chart.options.categoryAxis.categories = [];
chart.refresh();

Regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Uday
Top achievements
Rank 1
answered on 21 Dec 2018, 01:59 PM

Hi Team,

         Greetings from ECPL,

        I am facing same issue as above. I hope that you got solution for this issue.Please help me out on this.

 

 

 

Thanks and Regards,

Uday.

        

0
Preslav
Telerik team
answered on 25 Dec 2018, 08:03 AM
Hello Uday,

I tested the issue from this post, and it seems that it is no longer replicable:
Having said that, could you please elaborate on what is your scenario?


Regards,
Preslav
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Charts
Asked by
Juuso
Top achievements
Rank 1
Answers by
Iliana Nikolova
Telerik team
Uday
Top achievements
Rank 1
Preslav
Telerik team
Share this question
or