Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
725
How can I select / deselect points in XamDataChart, especially in BubbleSeries?
posted

Hi to All,

I would like to select/deselect (multiple) displayed points in a BubbleSeries, preferable with Click then Ctrl+Click. I suppose there will be 3 issues to solve:

Q1: How to catch the click then recognize what point is under the cursor? (what point was clicked)

Q2: How to change the point's appearance (say increase radius, by changing the binded data, any better idea?). Btw: Can I change the shape of an individual point, like from circle to square?

Q3: Maintain what is selected. (in a list.) (does any internal implementation for this?)

Thanks in advance

Parents
  • 35319
    Verified Answer
    posted

    Hi Justin,

     

    Thank you for your post. I have been looking into your requirement and in order to get the clicked underlying data item you could handle the ‘SeriesMouseLeftButtonDown’ event of the XamDataChart like:

     

            private void theChart_SeriesMouseLeftButtonDown(object sender, Infragistics.Controls.Charts.DataChartMouseButtonEventArgs e)

            {

                BubblePoint dataPoint = e.Item as BubblePoint; // where BubblePoint is the type of your data item

            }

     

    In order to notify that some data point is selected I am changing its color.

     

    I am attaching a sample application(DataChartBubbleSeriesSelection.zip) that shows my approach on how to select multiple items when pressing Ctrl key.

     

    Let me know, if you need any further assistance on this matter.

    DataChartBubbleSeriesSelection.zip
Reply Children
No Data