We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

WPF Chart

Thread ID:





71217 Jan 22,2008 06:10 PM UTC Jan 23,2008 04:58 AM UTC WPF 1
Tags: Chart
Bestin Abraham
Asked On January 22, 2008 06:10 PM UTC

How do i limit the maximum number of bar charts X item on a WPF Bar Chart from c#.


I want to horizontal scrolling feature and maintain minimum width of the Bar Graph.

I have a data count more than 50 and i couldn't even see it on the chart.

Any help will be appreciated

Administrator [Syncfusion]
Replied On January 23, 2008 04:58 AM UTC

Chart series width will be automatically increased on increasing the size of the chart area.
Adding a scroll viewer to the chart area is not a best use case. However if you need the scroll bar inside the chart area you can call the chart zooming command in the window load event. By doing this it will zoom the chart but the zooming kit will be displayed. A provision to disable the zooming kit is under development and will be available in the next release.

You can use the following code snippet to zoom the chart in the window load event.

ChartAreaCommands.SwitchZooming.Execute(null, Chart1.Areas[0]);
Chart1.Areas[0].PrimaryAxis.ZoomFactor = 0.5;
Chart1.Areas[0].PrimaryAxis.ZoomPosition = 0;
Chart1.Areas[0].SecondaryAxis.ZoomFactor = 0.5;
Chart1.Areas[0].SecondaryAxis.ZoomPosition = 0;

Let me know if you have further queries

Athaur Rahman GS


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon