asp.net-charts

custom label on x-axis

被刻印的时光 ゝ 提交于 2019-12-05 04:34:44
My chart predicts a value for the next 30 years. The first value must be displayed as year 1. Then year 5, 10... until 30. But internally the first year is 0 and is left off: I tried adding a custom label, but it only breaks the other labels: If I add it to AxisX2 instead of AxisX it does nothing. Here is the code to make the chart and add the lines: public static Chart MakeChart(string title) { var chart = new Chart(); var area = new ChartArea("GrafiekGebied"); foreach (var axis in area.Axes) { axis.TitleForeColor = defaultColor; axis.LineColor = defaultColor; axis.InterlacedColor =

Styling the asp.net charting controls

我的未来我决定 提交于 2019-12-04 06:56:13
Using the ASP.Net Chart Controls , which are a subset of the Dundas Chart Controls , How can I make charts that look like this: Instead of this: EDIT: I've made some progress , since asking this question. The styling elements that improve the default graph in both Dundas and MSChart are: Round Corners on the chart container Background colours and gradients on chart container Transparency on column colours Alignment of columns in the x axis (bizarely, MSChart defaults to z axis alignment) Area 3D wall width I know it's a bit late, but I was playing with the chart for a project I'm working on.

MSChart / Asp.net Charts don't show tooltips

旧时模样 提交于 2019-12-04 05:27:20
问题 I have a dashboard page in which I am using various MSCharts. I have a class defined for each one of these charts, in which I am defining Tooltips of the Series in that chart like below when I run through each chart class and define its Series properties. Series[0].ToolTip = "Date = #VALX{d}\nTotal Qty Shipped = #VALY"; The problem I'm seeing is because there are multiple charts on the page, each with its own chart area. The only chart that shows a tooltip is the first chart that has one

How do I force a chart to auto adjust Y Axis Maximum?

荒凉一梦 提交于 2019-12-03 23:50:47
问题 I have a .NET chart which I am populating at runtime The chart appears within a report. For each band in my report, I clear all the series and add them back in using code Series s = new Series(); s.Font = new Font("Verdana", 8f); int i = 0; foreach (var month in line.Months) { DataPoint p = new DataPoint(); p.XValue = i; p.YValues = new Double[] { month.LineValue ?? 0 }; s.Points.Add(p); i++; } When I populate the chart the second time, the Y Axis maximum stays on 2000, i.e. is not being

Spline chart smooth corners

只愿长相守 提交于 2019-12-02 09:36:30
问题 I am using Chart control from .NET framework in my project. I have added chart control to the form and configured as shown below. // Add a new series. chart1.Series.Add("1"); var series = chart1.Series[0]; series.ChartType = SeriesChartType.Spline; // Hide the legend. series.IsVisibleInLegend = false; // configure x axis. var cArea = chart1.ChartAreas[0]; cArea.AxisX.IntervalType = DateTimeIntervalType.Number; cArea.AxisX.LabelStyle.Format = "00"; cArea.AxisY.LabelStyle.Format = "0.000";

MSChart / Asp.net Charts don't show tooltips

好久不见. 提交于 2019-12-02 06:38:30
I have a dashboard page in which I am using various MSCharts. I have a class defined for each one of these charts, in which I am defining Tooltips of the Series in that chart like below when I run through each chart class and define its Series properties. Series[0].ToolTip = "Date = #VALX{d}\nTotal Qty Shipped = #VALY"; The problem I'm seeing is because there are multiple charts on the page, each with its own chart area. The only chart that shows a tooltip is the first chart that has one assigned to it. The other charts don't show anything even though similar code is run for them. Why does

Spline chart smooth corners

时光毁灭记忆、已成空白 提交于 2019-12-02 05:39:51
I am using Chart control from .NET framework in my project. I have added chart control to the form and configured as shown below. // Add a new series. chart1.Series.Add("1"); var series = chart1.Series[0]; series.ChartType = SeriesChartType.Spline; // Hide the legend. series.IsVisibleInLegend = false; // configure x axis. var cArea = chart1.ChartAreas[0]; cArea.AxisX.IntervalType = DateTimeIntervalType.Number; cArea.AxisX.LabelStyle.Format = "00"; cArea.AxisY.LabelStyle.Format = "0.000"; cArea.AxisY.LabelStyle.IsEndLabelVisible = true; cArea.AxisX.Minimum = 0; cArea.AxisX.Maximum = 100; cArea

How do I force a chart to auto adjust Y Axis Maximum?

可紊 提交于 2019-12-01 02:13:28
I have a .NET chart which I am populating at runtime The chart appears within a report. For each band in my report, I clear all the series and add them back in using code Series s = new Series(); s.Font = new Font("Verdana", 8f); int i = 0; foreach (var month in line.Months) { DataPoint p = new DataPoint(); p.XValue = i; p.YValues = new Double[] { month.LineValue ?? 0 }; s.Points.Add(p); i++; } When I populate the chart the second time, the Y Axis maximum stays on 2000, i.e. is not being recalculated How do I force recalculation? I have ScaleBreakStyle enabled on the Y Axis If I try to set

Line up X axis labels with chart columns (ASP.Net Chart control)

怎甘沉沦 提交于 2019-11-30 20:39:29
I'm trying to make a chart using the ASP.Net Chart control that has specific numerical values on the X axis and their frequency count on the Y axis. Here is an example of what I want from the charting framework I am replacing: In the above example, the X axis labels line up with the columns. But, with the ASP.Net Chart control, instead of labeling the columns which represent these specific values (e.g. 1492, 2984), the control is labeling at rounded intervals and not lining up with the columns (e.g. 2000, 4000) as you can see below: I found other similar postings that recommended setting the

Line up X axis labels with chart columns (ASP.Net Chart control)

天大地大妈咪最大 提交于 2019-11-30 05:04:27
问题 I'm trying to make a chart using the ASP.Net Chart control that has specific numerical values on the X axis and their frequency count on the Y axis. Here is an example of what I want from the charting framework I am replacing: In the above example, the X axis labels line up with the columns. But, with the ASP.Net Chart control, instead of labeling the columns which represent these specific values (e.g. 1492, 2984), the control is labeling at rounded intervals and not lining up with the