这个问题在MSChart论坛上已经无人问津超过一年了。
I'm continually getting an overflow exception on a chart. I'm setting up my chart as follows:
InstrChart.Legends.Clear(); dataArea = InstrChart.ChartAreas.Add("Instr1"); dataArea.AxisX.MajorGrid.Enabled = false; dataArea.AxisY.MajorGrid.Enabled = false; dataArea.CursorX.IsUserSelectionEnabled = true;
I'm then adding 12 series with about 10000 points each.
The exception occurs when I zoom down to show only 3 or 4 point per series. Immediately after I release the mouse button for a zoom I get the following exception:
System.OverflowException was caught Message="Overflow error." Source="System.Drawing" StackTrace: at System.Drawing.Graphics.CheckErrorStatus(Int32 status)
(etc - see link above for full trace.)
I've removed all event handler for the chart with no luck in stopping zooming from eventuall causing this exception. I've set IsUserSelectionEnabled to false for the chart and done zooming from code with no luck.
Any help on this issue would be great. Cheers.
这个异常似乎在你缩放“太远”(具体是多少可能有所不同),而无论图表的其余部分如何配置,都会出现。已经有几个人报告了这个问题。异常助手指示它在System.Drawing.dll中。
这里有人有任何线索或解决方法吗?