WPF MVVM Chart View Tooltips

2 posts, 0 answers
  1. Todd
    Todd avatar
    7 posts
    Member since:
    Nov 2014

    Posted 30 Mar 2015 Link to this post

    I'm working on a demo for our IT dept to see if the Telerik Chart View will meet our needs before we jump on board and purchase.  So I'm currentl working with a trial version.

    The attached project has a chart with Year bound to the XAxis and Coverage bound to the YAxis.  I need a tooltip to display the Coverage amount, and the Policy Number, which is another property of the model (along with Coverage and Year).  I can only get tooltips to display values that are bound to the XAxis and YAxis.  When I specify PolicyNumber in the tooltip, the tooltip shows nothing for that property.  I did something in the older RadChart quite easily. 

    Any help in how to solve this would be appreciated.  Thanks

    FYI, This thread wasn't allowing be t attached a zip file, so I renamed the extension to a jpg.  Hopefully yu can renamed is back to a zip and look at it.
  2. Petar Marchev
    Petar Marchev avatar
    996 posts

    Posted 31 Mar 2015 Link to this post

    Hi Todd,

    You are unable to attach a zip because this is a public forum, where you can only attach images. Zip files can be attached in support tickets only.

    In order to show a tooltip, you must plug in a tooltip behavior. As described in the help article, the data context in the tool tip template is data point. In order for you to reach the actual business item, you need to use the DataItem property, so you need to update your bindings similar to this:
    {Binding Path=DataItem.Profit}. 

    You can also check out our tooltip sdk sample here. Let us know how it goes.

    Petar Marchev

    See What's Next in App Development. Register for TelerikNEXT.

Back to Top