on mouse hover drill down

3 posts, 0 answers
  1. Abdulhameed
    Abdulhameed avatar
    27 posts
    Member since:
    Jul 2010

    Posted 01 Feb 2012 Link to this post

    I have two charts CountrySalesChart and RegionSalesChart, I would like when mouse hover the countrySalesChart, it updates the RegionSales.

    What I tried two approaches
    -The firs one I have added a HoverChanged event on the chartArea, however the chartArea includes the whole are not only the chartItems and it raised exceptions and it usually when you move the mouse a bit fast it raise the exception and stops.

    -The second approach is by adding a MouseBehavior to each DataItem in CountrySalesChart which is great but I couldn't access the RegionSalesChart to update in the chartItem_MouseEnter events, when I tried to access the chart I get the below error
    "An object reference is required for the non-static field"

    Any suggestion for a better method to achieve the desired result or an improvement to either of the above method will be highly appreciated.
  2. Petar Marchev
    Petar Marchev avatar
    968 posts

    Posted 06 Feb 2012 Link to this post


    I have attached a sample Silverlight 5 project that demonstrates how this functionality can be achieved. I have used a pie series but you can easily adopt it to any series you have used.

    Hope this is of help. Regards,
    Petar Marchev
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. DevCraft banner
  4. Abdulhameed
    Abdulhameed avatar
    27 posts
    Member since:
    Jul 2010

    Posted 06 Feb 2012 Link to this post

    Thanks a lot for your replay,

    I tried a similar approach however because of WCF async methods, the data was missed up.
    So, I decided to update data on click instead of on hover.
Back to Top