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

Stack only specific Series

3 Answers 69 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Mathias
Top achievements
Rank 1
Mathias asked on 03 Nov 2014, 09:24 AM
Hi i have a chart where i have 3 series.

The first series should be the total value (all requests) and the other 2 should be stacked (accepted / rejected requests).
How is this possible?
I can only get it working that all 3 series are stacked but thats not my goal.

.SeriesDefaults(seriesDefaults =>
seriesDefaults.Area().Line(line => line.Style(ChartAreaStyle.Smooth))
)
.Series(series =>
{
series.Area(Model.Requests).Name("Total requests").Stack(false);
series.Area(Model.AcceptedRequests).Name("Accepted requests").Stack(true);
series.Area(Model.RejectedRequests).Name("Rejected requests").Stack(true);
})

why is this not working?

3 Answers, 1 is accepted

Sort by
0
Hristo Germanov
Telerik team
answered on 04 Nov 2014, 07:45 AM
Hi Matthias,

In this case you can use named stack bar chart like in this online example: http://demos.telerik.com/aspnet-mvc/Beta/bar-charts/grouped-stacked-bar

Could you try this approach and tell me if it works for you?

Regards,
Hristo Germanov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Mathias
Top achievements
Rank 1
answered on 04 Nov 2014, 01:53 PM
i resolved my problem by using column bar charts but i wanted to use area charts but it looks like this is not possible.
But however line chart mixed with stacked column bar charts did the job also.

series.Line(Model.Requests).Name("Requests").Style(ChartLineStyle.Smooth);
series.Column(Model.AcceptedRequests).Name("Accepted").Stack(true).Color("green");
series.Column(Model.UnhandledRequests).Name("Not handled").Stack(true).Color("yellow");
series.Column(Model.RejectedRequests).Name("Rejected").Stack(true).Color("red");
0
Hristo Germanov
Telerik team
answered on 06 Nov 2014, 08:40 AM
Hi Mathias,

I confirm that there is no support for the area/line series.

Please excuse us for the inconvenience.

Regards,
Hristo Germanov
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
Mathias
Top achievements
Rank 1
Answers by
Hristo Germanov
Telerik team
Mathias
Top achievements
Rank 1
Share this question
or