Drag points up or down in a line series?

5 posts, 0 answers
  1. Sam
    Sam avatar
    67 posts
    Member since:
    Jun 2011

    Posted 06 Dec 2011 Link to this post


    Hi, we have an upcoming requirement that goes like this:

    "For a chart with multiple line series, users should be able to drag individual points up or down to a new value on the Y-axis, and have the line series recalculate either as the user drags, or once the user stops dragging. The new selection must update the underlying data source as well."

    I'm pretty sure that this is not an out-of-the-box feature with the RadChart - at this stage though I need to know if this is a feature that can be added on top of the RadChart (via a custom line series or something similar) or if it is in the 'too hard' basket.

    Can you provide any idea of how this functionality might be achieved with the RadChart or if it is too difficult to consider at the moment? A complete solution would be wonderful, of course!

    Thanks very much,

    Sam
  2. Giuseppe
    Admin
    Giuseppe avatar
    2363 posts

    Posted 09 Dec 2011 Link to this post

    Hello Sam,

    We have attached a sample application that achieves the desired functionality to get you started. Basically you need to add mouse event handling logic to the line series point marks and use the built-in methods provided by the chart axis for physical-to-data-unit conversion.

    Hope this helps.


    Greetings,
    Giuseppe
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
  4. Sam
    Sam avatar
    67 posts
    Member since:
    Jun 2011

    Posted 11 Dec 2011 Link to this post

    Brilliant! This is extremely helpful, thank you.

    This sample provides a great foundation for what we want to do, not to mention saving us a lot of time!

    Thanks!

    Sam
  5. Kevin
    Kevin avatar
    2 posts
    Member since:
    Oct 2011

    Posted 10 Jan 2012 Link to this post

    I have a very similar need, but my project uses WinForms.  Is there a similar example project for Winforms?
  6. Giuseppe
    Admin
    Giuseppe avatar
    2363 posts

    Posted 13 Jan 2012 Link to this post

    Hello Kevin,

    Unfortunately RadChart for Winforms does not expose similar functionality and it would not be possible to achieve the desired effect. One possible option is to use the RadChart for WPF control instead (RadChart for Silverlight and WPF share the same codebase) and host it inside a Winforms ElementHost.


    All the best,
    Giuseppe
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Back to Top
DevCraft banner