TeeChart入门

此链接可以作为参考http://tech.sina.com.cn/s/2008-07-07/1612722495.shtml

 

需要添加引用

using Steema.TeeChart;//tchart
using Steema.TeeChart.Styles;//bar

 

纯代码操作

TChart tChart1 = new TChart();
tChart1.Header.Lines = new string[] { "TeeChart" };
tChart1.Name = "tChart1";
tChart1.Dock = DockStyle.Fill;
tChart1.TabIndex = 0;

this.Controls.AddRange(new System.Windows.Forms.Control[] { tChart1 });//this是一个winform的窗体

Bar bar1 = new Bar();
bar1.Add(3, "Pears", Color.Red);
bar1.Add(4, "Apples", Color.Blue);
bar1.Add(2, "Oranges", Color.Green);

tChart1.Series.Add(bar1);

posted @ 2014-09-03 09:32  ChuckLu  阅读(1017)  评论(0编辑  收藏  举报