title | description | page_title | type | slug | position | tags | res_type |
---|---|---|---|---|---|---|---|
How to Prevent Scrolling the Parent ScrollViewer When Using the Zoom Functionality of RadCartesianChart. |
This article shows how you can prevent the parent ScrollViewer from scrolling when zooming in/out on/of RadCartesianChart. |
Handle Scrolling of the Parent ScrollViewer When Zooming In and Out of the RadCartesianChart. |
how-to |
kb-chartview-mousewheel-scrollviewer |
0 |
wpf, chartview, cartesianchart, chart, scroll, mouse wheel, wheel, zoom, zooming |
kb |
Product Version | 2024.2.514 |
Product | RadChartView for WPF |
Prevent the parent ScrollViewer
element from scrolling when using the zoom functionality of RadCartesianChart.
Subscribe to the MouseWheel
event of the RadCartesianChart
instance. In the event handler, set the e.Handled
property to True.
important Do not handle the
PreviewMouseWheel
event as it will disable the zoom functionality of the control.
{{region kb-chartview-mousewheel-scrollviewer-0}} private void RadCartesianChart_MouseWheel(object sender, MouseWheelEventArgs e) { e.Handled = true; } {{endregion}}