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

[Solved] LegendTitle and dynamic series?

5 Answers 168 Views
Chart for XAML
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Per
Top achievements
Rank 1
Per asked on 07 Feb 2013, 06:37 PM
Hi!

Is it possible to bind the LegendTitle property in a CategoricalSeriesDescriptor?
(I want to create a chart with dynamic series and a RadLegendControl)

Regards
Per

5 Answers, 1 is accepted

Sort by
0
Accepted
Giuseppe
Telerik team
answered on 08 Feb 2013, 10:08 AM
Hello Per,

Unfortunately currently RadChart does not provide legend support for scenarios with dynamic series generated via ChartSeriesProvider. I will forward your feedback to our developers for further consideration when planning the product backlog for the next release and you can also vote for this feature in our public ideas and feedback portal here (the higher the demand, the higher the priority).


Regards,
Giuseppe
the Telerik team
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
0
Per
Top achievements
Rank 1
answered on 12 Feb 2013, 08:56 PM
Hi again!

Is there a workaround for this? Can I create my own legend and extract the colors used in the chart?
If so, do you have any sample that can do this? :)

Regards
Per
0
Ivaylo Gergov
Telerik team
answered on 15 Feb 2013, 05:40 PM
Hi Per,

Thank you for your interest.

Yes, you can add LegendItems manually like this:
<Primitives:RadLegendControl x:Name="Legend1">
    <Primitives:RadLegendControl.LegendItems>
    <Primitives:LegendItem
        Title="FirstSeries" Fill="Blue" Stroke="Blue"/>        
    </Primitives:RadLegendControl.LegendItems>
</Primitives:RadLegendControl>

Also, you can extract the color from chart palette like this:
// Chart1 is the name of RadCartesianChart instance.
LegendItem item = new LegendItem();
item.Title = "FirstSeries";
item.Fill = Chart1.Palette.FillEntries.Brushes[0];
item.Stroke = Chart1.Palette.StrokeEntries.Brushes[0];
 
Legend1.LegendItems.Add(item);

I hope this is useful. 

 

Kind regards,
Ivaylo Gergov
the Telerik team
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
0
Scott
Top achievements
Rank 1
answered on 29 May 2013, 10:20 PM
Hi Giuseppe,

I'm not sure if it'll help move this feature up the list or not but I would really like this feature as well.

Thanks,

 
0
Ivaylo Gergov
Telerik team
answered on 30 May 2013, 01:24 PM
Hello Scott,

This feature will be included in our next official Q2 2013 release that will be available in mid-June.

Let me know if you have any other questions.

 

Regards,
Ivaylo Gergov
Telerik
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
Tags
Chart for XAML
Asked by
Per
Top achievements
Rank 1
Answers by
Giuseppe
Telerik team
Per
Top achievements
Rank 1
Ivaylo Gergov
Telerik team
Scott
Top achievements
Rank 1
Share this question
or