When the regular map is active, I use the following code to make the mouse jump to a specified position:
QueuedTask.Run(() =>
{
MapPoint mapPoint = MapPointBuilderEx.CreateMapPoint(x, y, spatialRef);
System.Windows.Point cursorPoint = MapView.Active.MapToScreen(mapPoint);
System.Windows.Forms.Cursor cursor = new Cursor(Cursor.Current.Handle);
Cursor.Position = new System.Drawing.Point((int)cursorPoint.X, (int)cursorPoint.Y);
});
When the Stereo Map is active and I use the same code as above, I get three problems:
1. I cannot specify the z-value
2. The mouse doesn't jump to the correct position on the Stereo Map
3. The position where the mouse jumps to is different each time I change the z-value of the mouse
Is there another way to set the mouse position in the StereoMap in the Pro SDK? I haven't found anything.