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

Varying number of DataSeries and declarative model

1 Answer 19 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Alexey Titov
Top achievements
Rank 1
Alexey Titov asked on 10 May 2010, 07:12 PM
Hi.

Can anyone suggest a walkaround how to have a chart that can display varying number of data series (data source can return a changing number of categories - some new added, some old - removed), using only a declarative model - without any C#/VB code behind?

TIA

1 Answer, 1 is accepted

Sort by
0
Velin
Telerik team
answered on 13 May 2010, 11:26 AM
Hi Alexey Titov,

The default behavior of RadChart is to automatically reflect all the changes of the items source as far as it is data bound to an observable collection. This should meet your criteria if you intend to set up a categorical chart.

In case you need to create a chart that needs to render different number of visual series depending on its data source you will need to provide a collection of SeriesMapping objects in you view  model that should be bound to the SeriesMappings property of the RadChart control.

In both cases you could find this example useful.

Best wishes,
Velin
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Chart
Asked by
Alexey Titov
Top achievements
Rank 1
Answers by
Velin
Telerik team
Share this question
or