AD
Administrator
Syncfusion Team
November 2, 2004 05:04 PM UTC
If these are non-virtual GridControls, the default copy support should copy all style information for you. But it will not copy things like row height/column widths since this is not part of the GridStyleInfo object.
So, to do this special copy/paste, you can handle the grid.ClipboardCopy event. In the handler, create a custom DataObject holding the information you want to persist, and put this object on the clipboard (setting e.Handled if you do not want the grid to continue its default copy support). Then to do the Paste, you would handle the grid.ClipboardPaste event. In your handler, you would retrieve your custom data object from the clipboard, and set the values from it on the grid.