This is the same problem someone else was having with the Silverlight chart controls: https://es.infragistics.com/community/forums/f/retired-products-and-controls/64311/is-any-way-of-creating-dynamically-stackedfragmentseries-of-a-stackedcolumnseries/327909#327909
My code is the same, except I'm using the WPF version of the controls. Can anyone help me out?
I'm using Graham Murray's workaround found at the bottom of page one of the above thread. Like the other poster, I can confirm that the converter is not being used even though it is referenced in the LegendItemTemplate.
I'm on version 11.2.20112.2046.
Thanks!
I have found a workaround. I attached an event handler to the StackedColumnSeries' SeriesCreated event:
private void stack_SeriesCreated(object sender, Infragistics.Controls.Charts.StackedSeriesCreatedEventArgs e) { StackedFragmentSeries series = (StackedFragmentSeries)sender; if (series != null) { series.Title = series.ValueMemberPath.Replace("_Count", string.Empty); } }
Replace "Count" with the ValueMemberPath of your datasource (GroupBy in my case).
I have the stackedColumnChart in silverlight and I am not able to achieve the goal. the sender I get is StackedColumnSeries and it has no ValueMemberPath... any idea of how can I get the names in the legend?
By the way, the stackedColumnSeries do not have a create event, only OnLoaded one
Hello,
You are right that the StackedColumnSeries doesn't have ValueMemberPath, but as toxoplasmotic said his sender is StackedFragmentSeries, which has ValueMemebrPath Property. If this is still an issue for you it will be great if you could send me an isolated sample project, where this is reproduced, so I can investigate it further for you.
Looking forward for your reply.