Hello Deivaselvan,
You hit upon what I was looking to do. Specifically, I need to check for duplicate string properties.
There appear to be 2 events for a paste:
GridPasteContent
PasteGridCellContent (it's only processing a cell at a time, too restrictive)
How do I access the entire clipboard contents from a handler to GridPasteContent?
Thanks.
|
this.dataGrid.GridPasteContent += dataGrid_GridPasteContent;
private void dataGrid_GridPasteContent(object sender, GridCopyPasteEventArgs e)
{
object text = Clipboard.GetText();
//Splits the row into number of cells by using \t.
text = Regex.Split(text.ToString(), @"\t");
var copyValue = (string[])text;
} |