Jump to content
Software FX Community

Error during repainting of scatter chart


DaveInCalgary
 Share

Recommended Posts

 I've encountered an error with the scatter chart when the chart is repainting itself.  The chart has multiple series, and the problem happens in a couple of different cases:

- after adding a large data series to the chart, and while it is still processing the data, change focus to another application then back to the chart app repeatedly and quickly. The error is unpredictable and won't happen if I don't switch the application focus.

- after adding new series data (doesn't matter how large) to the chart by a drag & drop operation, repeatedly drag & drop new series quickly. In this case, the error happens unpredictably, but usually after a dozen or so repetitions of the drag & drop.  The error won't happen if I don't repeat the drag & drop, or if I repeat the drop slowly.

When the error happens, a big red 'X' appears over the chart's panel, and the .NET error message box pops up.

Here is the call stack of the error that's issued while the windows message loop is being processed:

System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.Parameter name: seriesat ChartFX.WinForms.DataArray.get_Item(Int32 series, Int32 point)at ChartFX.WinForms.aw.l()at ChartFX.WinForms.aw.n()at ChartFX.WinForms.aw.u()at ChartFX.WinForms.aw.a(IFrame A_0, Int32& A_1)at ChartFX.WinForms.Chart.a(PaintBar A_0, IGraphicsEx A_1)at ChartFX.WinForms.ag.a(PaintEventArgs A_0)at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer, Boolean disposeEventArgs)at System.Windows.Forms.Control.WmPaint(Message& m)at System.Windows.Forms.Control.WndProc(Message& m)at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

Is there some way the prevent this from happening? Or can I at least handle this error myself before it gets to the problem during the repaint (so I can show a friendlier error message than the one .NET shows)

cheers,

Dave

CompactData.zip

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...