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

Multiple Series Binding to Charts

3 Answers 216 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Adwait
Top achievements
Rank 1
Adwait asked on 13 Oct 2014, 08:04 PM
I have an object that I have some data in. The object has the following properties

Description
Amount
Date

I want to plot a chart where Date would be in X axis and Amount will be on Y (which is easy). If I just set the ItemsSource and the X and Y properties, this works fine.

However for each distinct description I want to show a new series. But I want to keep this dynamic. so if there is Series 1 and Series 2 in Description, then only two would show, if there is more than 2 then all would show. How is this doable?

3 Answers, 1 is accepted

Sort by
0
Petar Marchev
Telerik team
answered on 14 Oct 2014, 07:32 AM
Hi Adwait,

You have opened this thread with the old RadChart as a product. We suggest you do not use it, but use the new ChartView instead. It is much faster, it resolves many of the limitations of the old charting component, it is very flexible and easy to set up.

It seems that you require grouping functionality, where a single items source is grouped into several objects, where each object has a Key the Description, and an associated list of items. The chartview does not provide grouoing capabilities out-of-the-box.

I think that the best way to go here is to declare an additional property in you view model SeriesModels which hold the grouped data. You can then use a SeriesProvider which will dynamically create as many series as SeriesModels you have.

References:
QSF SeriesProvider demo (one of many examples that uses the SeriesProvider)
Online help
SDK sample

Regards,
Petar Marchev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Adwait
Top achievements
Rank 1
answered on 14 Oct 2014, 03:27 PM
Petar,

Dont know why I am doing wrong but I download the DevCraft ultimate trial and in WPF I still dont see radchartview? What package does this belong to ?

Adwait
0
Petar Marchev
Telerik team
answered on 15 Oct 2014, 08:22 AM
Hello Adwait,

The ChartView is part of our wpf suite and Silverlight suite. The ChartView is not a control, it is a code name for a set of controls - RadCartesianChart, RadPolarChart, RadPieChart and ChartDataSource. Do look at the provided links where you will see this in work.


Regards,
Petar Marchev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Chart
Asked by
Adwait
Top achievements
Rank 1
Answers by
Petar Marchev
Telerik team
Adwait
Top achievements
Rank 1
Share this question
or