Title | | » | Improve ZedGraph handing of clipboard exceptions |
Assigned To | | » | Nick Shulman |
Type | | » | Defect |
Area | | » | Skyline |
Priority | | » | 3 |
Milestone | | » | 21.2 |
We have seen a number of these exceptions posted to the website:
System.Runtime.InteropServices.ExternalException (0x800401D0): Requested Clipboard operation did not succeed.
at System.Windows.Forms.Clipboard.ThrowIfFailed(Int32 hr)
at System.Windows.Forms.Clipboard.SetDataObject(Object data, Boolean copy, Int32 retryTimes, Int32 retryDelay)
at ZedGraph.ZedGraphControl.Copy(Boolean isShowMessage)
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
We should add exception handling to ZedGraph, as I did for Skyline clipboard operations. We should consider having our ZedGraph use ClipboardEx so that we can test it without using the system clipboard. Though, this may be more trouble than it is worth.