Tooltip binding

Hi,

I create a chartview with XBindingPath and YBindingPath, the series should show the Tooltips. My problem is, that the YBindingPath should show a value in percent - that works, but the Tooltip should show the real value. I have create a helper class
public class ChartValue
{
    /// <summary>
    /// Name
    /// </summary>
    public string Name
    {
        get;
        set;
    }
 
    /// <summary>
    /// Value
    /// </summary>
    public float Value
    {
        get;
        set;
    }
 
    /// <summary>
    /// Value in seconds
    /// </summary>
    public float Seconds
    {
        get;
        set;
    }
}

The current binding looks so: YBindingPath = nameof(ChartValue.Value). The Tooltip should show the Seconds value, is that possible? Thank you!  

2 Replies

MA Markus replied to Markus July 19, 2019 06:20 AM UTC

Hi,

I create a chartview with XBindingPath and YBindingPath, the series should show the Tooltips. My problem is, that the YBindingPath should show a value in percent - that works, but the Tooltip should show the real value. I have create a helper class
public class ChartValue
{
    /// <summary>
    /// Name
    /// </summary>
    public string Name
    {
        get;
        set;
    }
 
    /// <summary>
    /// Value
    /// </summary>
    public float Value
    {
        get;
        set;
    }
 
    /// <summary>
    /// Value in seconds
    /// </summary>
    public float Seconds
    {
        get;
        set;
    }
}

The current binding looks so: YBindingPath = nameof(ChartValue.Value). The Tooltip should show the Seconds value, is that possible? Thank you!  

Hi,

I found a solution. I have created a class that inherits from ChartTooltipBehavior , I override GetView and reset the ToolTip label.

Thank you.


SM Saravanan Madheswaran Syncfusion Team July 19, 2019 07:08 AM UTC

Hi Markus, 
 
We are glad that the reported problem was resolved at your end. Please let us know, if you have any other queries.  
 
Regards, 
Saravanan M 


Loader.
Up arrow icon