Cursor Tool Snap Change misses manual changes to XValue
Posted: Tue Jun 14, 2005 7:52 pm
A vertical Cursor Tool's OnSnapChange event does not fire if the cursor tool's X value has been changed programmatically and the next mouse movement is then back to the XValue the cursor tool was at before its XValue was changed.
Fill a line series with 10 values (FillSampleValues) so its X axis goes from 0 to 9.
Add a CursorTool with Snap true and FollowMouse true.
In the CursorTool's OnSnapChange event, display GetTickCount on a label so this event's firing can be detected.
Move the mouse to position the cursor at X=8 and move the mouse off the chart.
Click a button configured to set the cursortool's XValue = 1
The cursor will move to X=1
Now move the mouse back onto the chart at location X = 8. The cursor moves from X=1 to X=8 but the OnSnapChange event does not fire.
It seems as though manual changes to the cursortool's XValue are not passed onto whatever parameter the OnSnapChange method is comparing to. Any way to get this to happen ?
Fill a line series with 10 values (FillSampleValues) so its X axis goes from 0 to 9.
Add a CursorTool with Snap true and FollowMouse true.
In the CursorTool's OnSnapChange event, display GetTickCount on a label so this event's firing can be detected.
Move the mouse to position the cursor at X=8 and move the mouse off the chart.
Click a button configured to set the cursortool's XValue = 1
The cursor will move to X=1
Now move the mouse back onto the chart at location X = 8. The cursor moves from X=1 to X=8 but the OnSnapChange event does not fire.
It seems as though manual changes to the cursortool's XValue are not passed onto whatever parameter the OnSnapChange method is comparing to. Any way to get this to happen ?