Y Axis

In a line style chart, I want to set min et max value on the Y axis and be sure to have a line on Zero. Matthieu

4 Replies

RS Rune Selvaag September 12, 2005 11:14 AM UTC

Here is a sample of y-axis from 0-100 and interval 20: chart.PrimaryYAxis.RangeType = ChartAxisRangeType.Set; chart.PrimaryYAxis.Range = new MinMaxInfo(0, 100, 20); Don''t know what you mean by "sure to have a line on zero". Regards Rune >In a line style chart, I want to set min et max value on the Y axis and be sure to have a line on Zero. > >Matthieu


GM Geetha M Syncfusion Team September 13, 2005 09:03 AM UTC

Hi Matthieu, Thanks for your interest in Syncfusion products. By setting the Range property, you can plot a line chart with origin (0,0) and minimum and maximum value of Y-Axis set at 10 and 50 respectively. The following code snippet illustrates this: this.chartControl1.PrimaryYAxis.Range = new MinMaxInfo(0,50,10); this.chartControl1.PrimaryXAxis.Range.Min = 0; Please let me know if you have any questions. Regards, Geetha.


MP Matthieu Pero September 14, 2005 02:46 PM UTC

yes, but I have negative values and I want my line chart goes from the min value to the max value and have a line at 0. Matthieu


GM Geetha M Syncfusion Team September 15, 2005 02:25 PM UTC

Hi Matthieu, Please refer the sample attached below. It has a line chart with both positive and negative values and gridline falls on zero. LineChart_693.zip I hope this will help you. Please let me know if you have any questions. Regards, Geetha.

Loader.
Up arrow icon