daviddam Posted July 11, 2008 Report Share Posted July 11, 2008 I am trying to customize the tooltips for a series through code. I am setting the ToolTips.Format property to "%v on %x" but I am seeing the series name on the tooltip when it appears. I have tried other formatting but the series name always appears on the first line of the tooltip. Am I doing something wrong? Thanks! I'm using build 0.8.3111.29088. SeriesAttributes series = new SeriesAttributes();series.ToolTips.Format = cSeries.ToolTips.Format; Quote Link to comment Share on other sites More sharing options...
JuanC Posted July 18, 2008 Report Share Posted July 18, 2008 Because we support visuals to represent a series (using the Series.ContentTemplate) property it is not possible to include the series in our built-in format, in previous versions (.NET WinForms, ASP.NET) our default Format was something like "%s\n%v" so if you changed the format you could control whether the series name was visible or not. With our new approach you will have to change the template used for the Tooltips. You can do so by modifying ToolTips.Template as follows <DataTemplate x:Key="MyToolTip"> <TextBlock Text="{Binding Path=ToolTip}" /></DataTemplate>chart1.AllSeries.ToolTips.Template = (DataTemplate) FindResource("MyToolTip");Regards, JuanC Quote Link to comment Share on other sites More sharing options...
daviddam Posted July 18, 2008 Author Report Share Posted July 18, 2008 OK, that makes sense. Thank you for the code as well. Dave Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.