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

LegendDisplayMode = ItemLabels is not working in Preview Mode and Designer

4 Answers 131 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Rob
Top achievements
Rank 1
Rob asked on 09 Feb 2011, 06:56 PM
Hi,

I have been working through the documentation, tutorials, and demos for the past day and I am running into problems with setting up a pie chart.  I have databound the chart, and want the Legend labels to match the column name that I specified with the DataLabels property.  After looking through the Product Line Sales example code, I discovered that this could be done by setting the LegendDisplayMode to ItemLabels on the Series Appearance properties window.  

When I set LegendDisplayMode to ItemLabels, the designer appears to update like I expect - the Series name is replaced with a list (Item 1, Item 2, etc. see image 1 that I have attached). However, when I preview the report, the legend has reverted back to showing the Series name.  Why is this happening?  In addition, if I close the report and re-open, the designer displays the series name again (see image 2).  

I have looked at the designer-generated code in the code-behind, and the LegendDisplayMode is still set to ItemLabels (image 3).   What is happening?  Am I overlooking a property?  This should be very simple, and it appears to work perfectly in the Product Line Sales example!

Thanks, 

Rob

4 Answers, 1 is accepted

Sort by
0
Rob
Top achievements
Rank 1
answered on 10 Feb 2011, 04:10 PM
bump, somebody help me out plz!!! Do I have to build the legend myself on a databound event?  I didn't see this in the product line sample.
0
Rob
Top achievements
Rank 1
answered on 10 Feb 2011, 06:49 PM
Well, I just ended up resetting these values in the ItemDataBound event.  It seems weird to me that they get reset before the item is databound, though.  
0
Dwight
Top achievements
Rank 1
answered on 17 May 2012, 12:10 AM
Hi Rob

I know you resolved this a long time ago but I am having the exact same issue as you and I too am unable to get a response as to what is going wrong

You said that you fixed it using the onDataBound event, can I ask what you did for the workaround

Thx if you can assist in any way

Regards

Dwight
0
Steve
Telerik team
answered on 17 May 2012, 10:33 AM
Hi guys,

There is no known bug for this functionality and in fact our ProductLineSales demo report contains a pie chart with LegendDisplayMode set to ItemLabels that works as expected. Those demos are installed along with the product so you can open the report locally and review it. One thing that could intervene with any settings of the chart (not only styles) is the Skin property which can override such settings. So if you're using a Skin, it is a good idea to set the customizations of the chart in the report constructor after InitializeComponent or style the whole chart manually (i.e. without setting a Skin).

All the best,
Steve
the Telerik team

BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

Tags
General Discussions
Asked by
Rob
Top achievements
Rank 1
Answers by
Rob
Top achievements
Rank 1
Dwight
Top achievements
Rank 1
Steve
Telerik team
Share this question
or