SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and now iOS Charting & Android Chart Components
Please use the forums below to ask questions about SciChart. Take a moment to read our Question asking guidelines on how to ask a good question and our support policy. We also have a tag=SciChart on Stackoverflow.com where you can earn rep for your questions!
Please note: SciChart team will only answer questions from customers with active support subscriptions. Expired support questions will be ignored. If your support status shows incorrectly, contact us and we will be glad to help.
I have two column charts which have been rotated so the y axis is horizontal and the x axis vertical. I am trying to capture the click on the column to display information. In my left button up event, I do a hit test and process it. I have noticed that sometimes the cursorModifier.seriesData is empty. This seems to happen at random.
This is the code I’m using
var hitTestPoint = e.GetPosition(domChart.GridLinesPanel as UIElement); var modifierGroup = ((ModifierGroup)domChart.ChartModifier); var cursorModifier = ((CursorModifier)modifierGroup.ChildModifiers); //var cursorModifier = ((CursorModifier)domChart.ChartModifier); var seriesInfos = cursorModifier.SeriesData.SeriesInfo;
Given the dynamic nature of this chart, I recreate the data series every 250 ms. I have the data series bound to my view model and every 250 ms I assign the series property a new Dataseries. Could this be the reason I’m seeing this issue.
Please let me know.
[Comment] Hi Deepak,
It sounds like it. What is it you need from the SeriesInfo? The X and Y positions / data values? If so there may be another way to achieve this.
Let me know,
Try these two links, they provide info about our HitTest API:
// Hit Testing: Getting data values at mouse points
// CoordinateCalculators: Convert data-value to pixels
Please login first to submit.