The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
How do I validate the range of cells being pasted into a syncfusion grid?
Basically, I have an application with a grid that's 10 columns long. I want to make sure that when a user pastes contents from Excel, the application can validate to ensure that the pasted contents are a grid of 10 columns.
I know that I can use: this.gridGroupingControl1.TableModel.ClipboardPaste += new GridCutPasteEventHandler(TableModel_ClipboardPaste);
But within the actual TableModel_ClipboardPaste(...) method I only know of how to retrieve the clipboard contents as a string. is there a neater way?
YVYuvaraja V Syncfusion Team December 9, 2010 10:54 AM UTC
Hi Gav,
Thanks for using syncfusion products.
The default behavior for a gridControl is to paste what is on the clipboard and append rows and columns if neccessary.To avoid you would use the "ClipboardFlags" property.It prevents the appending of rows and columns.The following code illustrates the same. e.ClipboardFlags = GridDragDropFlags.NoAppendCols; e.ClipboardFlags = GridDragDropFlags.NoAppendRows;