Profile Picture

Scroll Axis of zoomed chart

Posted By shweta jain Last Year
Author
Message
shweta jain
Question Posted Last Year
View Quick Profile
Junior Member

Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)Junior Member (21 reputation)

Group: Forum Members
Last Active: Last Year
Posts: 14, Visits: 185
Hello,
I want to scroll both primary x and primary y axis of chart after zoom.
How can I add this axis scrolling after zoom in the chart?
I have tried by adding NDataPanTool in the chart by taking reference of example of DataPanTool. but it does not work.
- chartControl.Controller.Tools.Add(new NDataPanTool()).
Is it affected by cursor type? I am also using NAxisCursor in the same chart.

Can you Please provide me code for "Axis scrolling in the chart"

Nevron Support
Posted Last Year
View Quick Profile
Supreme Being

Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)Supreme Being (4,063 reputation)

Group: Forum Members
Last Active: 39 minutes ago
Posts: 2,945, Visits: 3,306

Hi Shweta,

The following code shows how to configure thechart for zooming and scrolling:

NCartesianChart chart =(NCartesianChart)nChartControl1.Charts[0];
chart.Axis(StandardAxis.PrimaryX).ScrollBar.Visible= true;
chart.Axis(StandardAxis.PrimaryY).ScrollBar.Visible= true;
chart.RangeSelections.Add(new NRangeSelection());

NPointSeries point = new NPointSeries();
point.Values.Add(10);
point.Values.Add(20);
point.Values.Add(30);
chart.Series.Add(point);

nChartControl1.Controller.Tools.Add(newNPanelSelectorTool());
nChartControl1.Controller.Tools.Add(newNAxisScrollTool());
nChartControl1.Controller.Tools.Add(newNDataZoomTool());
nChartControl1.Controller.Tools.Add(newNDataPanTool());

You can also take a look at the examples in the Interactivity / Tools section onhow to configure all the features in each tool individually.



Best Regards,
Nevron Support Team





Similar Topics


Reading This Topic