RadPieChart Labels

2 posts, 0 answers
  1. Andrew
    Andrew avatar
    18 posts
    Member since:
    Sep 2012

    Posted 24 Oct 2012 Link to this post

    Is it possible to get a label to show up when your mouse moves over a pie slice? The label would contain info on the pie slice i.e. its value.
  2. Petar Kirov
    Admin
    Petar Kirov avatar
    425 posts

    Posted 26 Oct 2012 Link to this post

    Hi Andrew,

    I believe that the feature you are talking about is tooltips. You can enable them by adding ChartTooltipBehavior to the Behaviours collection of ChartView (including RadPieChart). You can also define your custom template for the tooltips in which you can choose the information you want to display (for example the percentage of the datapoint and some other property of the underlying dataitem).
    Here is an example: 
    <telerik:RadPieChart x:Name="pieChart">
        <telerik:RadPieChart.Behaviors>
            <telerik:ChartTooltipBehavior/>
        </telerik:RadPieChart.Behaviors>
                 
        <telerik:RadPieChart.TooltipTemplate>
            <DataTemplate>
                <StackPanel>
                    <TextBlock Text="{Binding Percent}"/>
                    <TextBlock Text="{Binding DataItem.Name}"/>


    Regards,
    Petar Kirov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft banner
Back to Top