private void Drawing(string type, string department) { Charting c = new Charting(); c.Title = "缺勤情况"; c.XTitle = "周次"; c.YTitle = "人数(人)"; c.PicHight = 300; c.PicWidth = 884; c.PhaysicalImagePath = "ChartImages";//统计图片存放的文件夹名称,缺少对应的文件夹生成不了统计图片 c.FileName = "Statistics51aspx"; if (type == "Column") { c.Type = SeriesType.Column; } else { c.Type = SeriesType.Spline; } if (department == "1") { c.DataSource = GetDataSource(1, 7); } else if (department == "2") { c.DataSource = GetDataSource(1, 1); } else if (department == "3") { c.DataSource = GetDataSource(2, 2); } else if (department == "4") { c.DataSource = GetDataSource(3, 3); } else if (department == "5") { c.DataSource = GetDataSource(4, 4); } else if (department == "6") { c.DataSource = GetDataSource(5, 5); } else if (department == "7") { c.DataSource = GetDataSource(6, 6); } else if (department == "8") { c.DataSource = GetDataSource(7, 7); } c.Use3D = false; c.CreateStatisticPic(this.Chart1); }
private void Drawing1(string department) { Charting c1 = new Charting(); c1.Title = "作业分析情况"; c1.XTitle = "周次"; c1.YTitle = "未完成作业次数(次)"; c1.PicHight = 200; c1.PicWidth = 800; c1.PhaysicalImagePath = "ChartImages1";//统计图片存放的文件夹名称,缺少对应的文件夹生成不了统计图片 c1.FileName = "Statistics51aspx"; c1.Type = SeriesType.Column; if (department == "信息与艺术系") { c1.DataSource = GetDataSource1(1, 1); } else if (department == "建筑系") { c1.DataSource = GetDataSource1(2, 2); } else if (department == "机电系") { c1.DataSource = GetDataSource1(3, 3); } else if (department == "机械工程系") { c1.DataSource = GetDataSource1(4, 4); } else if (department == "食品工程系") { c1.DataSource = GetDataSource1(5, 5); } else if (department == "经济管理系") { c1.DataSource = GetDataSource1(6, 6); } else if (department == "商务外语系") { c1.DataSource = GetDataSource1(7, 7); } c1.Use3D = false; c1.CreateStatisticPic(this.Chart2); c1.Use3D = true; }
private void Drawing(string type, string department) { Charting c = new Charting(); c.Title = "缺勤情况"; c.XTitle = "周次"; c.YTitle = "人数(人)"; c.PicHight = 300; c.PicWidth = 800; c.PhaysicalImagePath = "ChartImages";//统计图片存放的文件夹名称,缺少对应的文件夹生成不了统计图片 c.FileName = "Statistics51aspx"; c.Type = SeriesType.Column; if (department == "信息与艺术系") { c.DataSource = GetDataSource(1, 1); } else if (department == "建筑系") { c.DataSource = GetDataSource(2, 2); } else if (department == "机电系") { c.DataSource = GetDataSource(3, 3); } else if (department == "机械工程系") { c.DataSource = GetDataSource(4, 4); } else if (department == "食品工程系") { c.DataSource = GetDataSource(5, 5); } else if (department == "经济管理系") { c.DataSource = GetDataSource(6, 6); } else if (department == "商务外语系") { c.DataSource = GetDataSource(7, 7); } c.Use3D = false; c.CreateStatisticPic(this.Chart1); }