当前位置 : 主页 > 网络编程 > net编程 >

.net web图表类

来源:互联网 收集:自由互联 发布时间:2023-10-08
用法: Response.ContentType = "image/png"; string[] xValues, yValues; LineChart line = new LineChart(Color.White); line.VerticalLabel = "告警数量"; line.ShowLegend = false; line.ShowData = true; line.Height = 250; line.Width = 250; G

.net web图表类_数据


用法:

Response.ContentType = "image/png";
string[] xValues, yValues;
LineChart line = new LineChart(Color.White);
line.VerticalLabel = "告警数量";
line.ShowLegend = false;
line.ShowData = true;
line.Height = 250;
line.Width = 250;
GetValues(out xValues, out yValues); //填充数据
line.CollectDataPoints(xValues, yValues);
Bitmap StockBitMap = line.Draw();
MemoryStream memStream = new MemoryStream();
StockBitMap.Save(memStream, ImageFormat.Png);
memStream.WriteTo(Response.OutputStream);

  




上一篇:C#集合类使用范例
下一篇:没有了
网友评论