We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Chart Series ToolTip

Thread ID:

Created:

Updated:

Platform:

Replies:

100826 Sep 8,2011 06:47 AM Sep 9,2011 01:17 AM Silverlight 1
loading
Tags: Chart
Nicolas Crignon
Asked On September 8, 2011 06:47 AM

Hello,
I can not code the tooltip dynamically insert in a Chart series itself dynamically insert.

To sum up, I add a dynamic series in my chart in code behind and this series, I must add a tooltip for the values ​​of my curve.

In the guide we find this:






it is exactly what i would but i can not code this in code behind.


i have this actually:
Chart.Areas[0].Series[x].DataSource = myData;
Chart.Areas[0].Series[x].BindingPathX = "Date";
Chart.Areas[0].Series[x].BindingPathY = new List() {"Value"};

ToolTip myToolTip = new ToolTip();
Binding c = new Binding();

c.source = Chart.Areas[0].Series[x];
c.Path = new PorpertyPath("currSegment.DataPoint.X");
myToolTip.SetBinding(ToolTip.ContentProperty, c);
myToolTip.Template = ...
ToolTipService.SetToolTip(Chart.Areas[0].Series[x], myToolTip);



sorry for my bad english

Thanks in advance



Michael Prabhu M [Syncfusion]
Replied On September 9, 2011 01:17 AM

Hi Nicolas,

Thanks for using Syncfusion products.

We have analyzed your requirement, your requirement can be achieved by creating tooltip in MouseEnter event for chartseries as in below code snippet.

Code snippet[c#]:

void series_MouseEnter(object sender, ChartMouseEventArgs e)
{
mytooltip.Content = Convert.ToString(chart.Areas[0].Series[0].currSegment.DataPoint.Y);
mytooltip.IsOpen = true;
ToolTipService.SetToolTip(chart.Areas[0].Series[0], mytooltip);
}

Based on your requirement we have created and attached a sample.

Please let us know if you have any queries.

Thanks,
Michael Prabhu.



Tooltip_781d20dd.zip

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;