首页 > 代码库 > 通过直接编码添加折线图到ChartControl
通过直接编码添加折线图到ChartControl
https://documentation.devexpress.com/#WindowsForms/CustomDocument2976
ChartControl lineChart = new ChartControl(); Series series1 = new Series("Series 1", ViewType.Line); series1.Points.Add(new SeriesPoint(1, 2)); series1.Points.Add(new SeriesPoint(2, 12)); series1.Points.Add(new SeriesPoint(3, 14)); series1.Points.Add(new SeriesPoint(4, 17)); lineChart.Series.Add(series1); //series1.ArgumentScaleType = ScaleType.Numerical; //((LineSeriesView)series1.View).LineMarkerOptions.Kind = MarkerKind.Triangle; //((LineSeriesView)series1.View).LineStyle.DashStyle = DashStyle.Dash; //((XYDiagram)lineChart.Diagram).EnableAxisXZooming = true; //lineChart.Legend.Visibility = DefaultBoolean.; //lineChart.Titles.Add(new ChartTitle()); //lineChart.Titles[0].Text = @"A Line Chart"; lineChart.Dock = DockStyle.Fill; this.Controls.Add(lineChart);
通过直接编码添加折线图到ChartControl
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。