The trackball feature of the control is very useful when you want to allow the end user to quickly take a look at the chart from a different angle. In this mode the chart will modify the Elevation and Rotation parameters of the NProjection object attached to the chart. To enable the trackball you must add a NTrackballTool object to the Tools collection.
C# |
Copy Code
|
---|---|
chartControl.Controller.Tools.Add(new NSelectorTool()); chartControl.Controller.Tools.Add(new NTrackballTool()); |
Visual Basic |
Copy Code
|
---|---|
chartControl.Controller.Tools.Add(New NSelectorTool) chartControl.Controller.Tools.Add(New NTrackballTool) |
Now when the user presses the left mouse button and drags the mouse over the control window the change in the X direction will modify the Rotation and the change in the Y direction will modify the Elevation of the current chart. The NTrackballTool will raise the ProjectionChanged event when the projection of the chart changes.