By Florian Heck - 5 Years Ago
|
Hi Team, I am using the Data Cursor in my chart and it is working well. But I also got some issues with it: 1) First I want to activate/deactivate the data cursor with a checkbox. Activating is nor problem, but when I want to deactivate the cursor the lines stay in the chart (picture below) So is there any way to remove these lines?
2) The second thing is: The data cursor should follow the graph in the chart. At the moment you can move it free Is there a command to fix the cursor on the graph?
Thanks for helping! Best regards!
Code:
If CheckBox2.Checked = True Then
axisCursorY.BeginEndAxis = CType(StandardAxis.PrimaryY, Integer) chart.Axis(StandardAxis.PrimaryX).Cursors.Add(axisCursorY)
axisCursorY.Value = 0
NChartControl1.Controller.Selection.SelectedObjects.Add(chart) NChartControl1.Controller.Tools.Add(New NDataCursorTool())
axisCursorY.SynchronizeOnMouseAction = MouseAction.Move
axisCursorX.BeginEndAxis = CType(StandardAxis.PrimaryX, Integer) chart.Axis(StandardAxis.PrimaryY).Cursors.Add(axisCursorX)
axisCursorX.Value = 0
NChartControl1.Controller.Selection.SelectedObjects.Add(chart) NChartControl1.Controller.Tools.Add(DataCursor1)
axisCursorX.SynchronizeOnMouseAction = MouseAction.Move
Else
NChartControl1.Controller.Tools.Clear()
End If
|
By Nevron Support - 5 Years Ago
|
Hi Florian, Thank you for your interest in Nevron Chart for .NET!
1) First I want to activate/deactivate the data cursor with a checkbox. Activating is nor problem, but when I want to deactivate the cursor the lines stay in the chart (picture below) So is there any way to remove these lines? You'll have to remove the cursor from the Cursors collection and refresh the chart. We'll add a Visible property to the axis cursor to make this easier. 2) The second thing is: The data cursor should follow the graph in the chart. At the moment you can move it free Is there a command to fix the cursor on the graph? Is there a command to fix the cursor on the graph? There is no way currently to fix the cursor to the last data point but you can implement this by dynamically modifying the Value property of the cursor when you add new data to the line series.
Hope this helps - let us know if you have any questions.
|
|