我创建折线图,但我想在X轴上显示从0开始的图表.我怎样才能做到这一点.
我尝试了一些方法,但仍然没有得到我想要的.
Chart1.ChartAreas[0].AxisX.Interval = 0;
Chart1.ChartAreas[0].AxisX.IsStartedFromZero = true;
Chart1.ChartAreas[0].AxisX.Minimum = 0;
Chart1.ChartAreas[0].AxisX.Crossing = 0;
Run Code Online (Sandbox Code Playgroud)
这就是我现在所做的

这就是我要的

还有一个,如何在图表中设置主要和次要单位..?
我的代码在这里
protected void Page_Load(object sender, EventArgs e)
{
System.Drawing.Font axisFont = new System.Drawing.Font("Arial", 8, System.Drawing.FontStyle.Bold);
System.Drawing.Font titleFont = new System.Drawing.Font("Arial", 10, System.Drawing.FontStyle.Bold);
Chart1.Width = 600;
Chart1.Height = 400;
Chart1.BorderlineColor = System.Drawing.Color.Black;
Chart1.BorderlineWidth = 1;
Chart1.BorderlineDashStyle = ChartDashStyle.Solid;
double[] min = { 60.9, 0, 28.81, 7.27 };
double[] ave = { 60.9, 0, 28.81, 7.27 };
double[] max = { 5167.72, 1.27, 4176.16, 2566.59 …Run Code Online (Sandbox Code Playgroud)