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

Area chart in multiple panes

4 Answers 103 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Pedro
Top achievements
Rank 1
Pedro asked on 18 Apr 2016, 12:50 PM

Hi! I need to be able to create graphs in multiple panes. But when I define an area chart in a second pane the colors stay above the line. I need it to stay under so that it makes more sense. 

 

I'll leave an atachment with an example

 

Any help?

4 Answers, 1 is accepted

Sort by
0
Accepted
Patrick | Technical Support Engineer, Senior
Telerik team
answered on 18 Apr 2016, 09:26 PM
Hello Pedro,

After recreating your issue with 3 Kendo Area Charts in this Telerik Dojo, I've found a solution for you.

Please take a look at the following sample which illustrates how to set the CategoryAxis in the series.

In the first Dojo, the categoryAxis is not set in the series.  By default, all charts will share the first categoryAxis.
$("#chart").kendoChart({.
  ...
  series: [
    { data: [1, 2, 3, 1], axis: "firstValueAxis", type: "area" },
    { data: [1, 3, 2, 1], axis: "firstValueAxis", type: "line" },
    ...
  ],

In the second Dojo, I included series.CategoryAxis so the series know which categoryAxis to use:
$("#chart").kendoChart({
  ...
  series: [
    { data: [1, 2, 3, 1], axis: "firstValueAxis", categoryAxis: "firstCategoryAxis", type: "area" },
    { data: [1, 3, 2, 1], axis: "firstValueAxis", categoryAxis: "firstCategoryAxis",  type: "line" },
    ...
  ],

Hope this helps!

Regards,
Patrick
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Pedro
Top achievements
Rank 1
answered on 19 Apr 2016, 01:50 PM
It was exactly this that I needed. Thanks!!!
0
Pedro
Top achievements
Rank 1
answered on 19 Apr 2016, 02:01 PM
It was exactly this that I needed. Thanks!!!
0
Patrick | Technical Support Engineer, Senior
Telerik team
answered on 19 Apr 2016, 02:04 PM
Hi Pedro,

Glad to help, and that everything is working!

Regards,
Patrick
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Charts
Asked by
Pedro
Top achievements
Rank 1
Answers by
Patrick | Technical Support Engineer, Senior
Telerik team
Pedro
Top achievements
Rank 1
Share this question
or