string[] X= new string[5] { "12","23","34","45","86" };
string[] Y = new string[5] { "102", "203", "304", "405", "506" };
5個點中的Y軸資料都能顯示出來 ,但是X軸數值顯示不出來是怎么回事,X坐標軸也沒有刻度顯示
chart1.ChartAreas[0].AxisX.Minimum = 0;
chart1.ChartAreas[0].AxisY.Minimum = 0;
chart1.ChartAreas[0].AxisX.Maximum = 80;
chart1.ChartAreas[0].AxisY.Maximum = 1000;
chart1.ChartAreas[0].AxisX.Interval = 20;
chart1.ChartAreas[0].AxisY.Interval = 100;
chart1.Series[0].IsValueShownAsLabel = true;
chart1.BorderlineWidth = 3;
string[] X= new string[5] { "12","23","34","45","86" };
string[] Y = new string[5] { "102", "203", "304", "405", "506" };
chart1.Series[0].Points.AddXY(X[0],Y[0]);
chart1.Series[0].Points.AddXY(X[1], Y[1]);
chart1.Series[0].Points.AddXY(X[2], Y[2]);
chart1.Series[0].Points.AddXY(X[3], Y[3]);
chart1.Series[0].Points.AddXY(X[4], Y[4]);
想用兩個陣列中的5個點,在MSchart圖表中畫5個點,
轉載請註明出處,本文鏈接:https://www.uj5u.com/net/89046.html
標籤:C#
下一篇:通過clr封裝c++介面時Marshal::PtrToStructure()封送到托管物件double型別屬性值出錯
