How can I retrieve the numerical value and the percentage value for "Other" if I was using the OthersCategoryThreshold functionality? I need it for the tooltip and the ItemLegend. In the image below, it shows how I've put the domain names and the range values next to it both for the legend and the tooltip using the included sample code.
<ig:ItemLegend Name="SamplesByRacePieChartLegend" VerticalAlignment="Top" HorizontalAlignment="Right"/><ig:XamPieChart Name="RacePieChart" DataContext="{Binding SamplesByRace, Converter={StaticResource ChartDataValueConverter} ItemsSource="{Binding}" LabelMemberPath="RaceNameWithCommaFormattedCount" LabelsPosition="Center" ValueMemberPath="Count" Legend="{Binding ElementName=SamplesByRacePieChartLegend}" OthersCategoryThreshold="5" OthersCategoryType="Percent"OthersCategoryText="Other"><ig:XamPieChart.ToolTip><StackPanel Orientation="Vertical"><TextBlock Text="{Binding Item.RaceName}" FontWeight="Bold" /><StackPanel Orientation="Horizontal"><TextBlock Text="{Binding Item.CommaFormattedCount}" Foreground="Black"/></StackPanel></StackPanel></ig:XamPieChart.ToolTip></ig:XamPieChart>
Thanks Valerie. This works for me!!
Hello,
In order to display the total for the others collection you would need to use a converter to sum the slices.
Please see attached sample.
Let me know if you have any questions.
Sincerely,ValerieDeveloper Support Engineer Infragisticswww.infragistics.com/support
Thanks. I get this to work if showing a percent value as you have. However if I want to show a numeric value rather than a percentage, what should I put in the tooltip textblock binding instead of PercentValue? :
<ig:XamPieChart.ToolTip>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding ItemLabel}"/>
<TextBlock Text="{Binding PercentValue, StringFormat=F2}" Margin="5,0,0,0"/>
</StackPanel>
</ig:XamPieChart.ToolTip>
I tested this with build 12.2.20122.1001 and the percentage value shows as expected.
Sincerely,
Valerie
Developer Support Engineer
Infragistics
www.infragistics.com/support
Hi Valerie
I am using InfragisticsSL5.v12.2 and am still seeing this issue with the series label for the Others category. Please advise.
Thanks