mschart.
也可以用第3方的.
mschart出了个最新版,.net3.5sp1版的。
不过目前资料基本都是e文的。
这个mschart功能很强大,而且似乎很方便,传入2个数组,一个横轴一个纵轴就OK了。这是最简单的用法,具体看ms的说明吧,不过是e文。
下面是个例子,画饼图的。
using System.Windows.Forms.DataVisualization.Charting;
//这个namespace必须装.net3.5sp1和mschart后才能using.
...
// initialize an array of doubles for Y values
double [] yval = ;
// initialize an array of strings for X values
string [] xval = ;
// bind the arrays to the X and Y values of data points in the "ByArray" series
chart1.Series["ByArray"].Points.DataBindXY(xval,yval);
// now iterate through the arrays to add points to the "ByPoint" series,
// setting X and Y values
for(int i = 0; i < 5; i++)
{
chart1.Series["ByPoint"].Points.AddXY(xval[i], yval[i]);
}