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.
It seems like this should be easy, but I have searched the knowledge base, help files, and forums without finding the answer :)
How can I prevent a specific ROW from being dragged, if the AllowDragSelectedRows is set to True. This is in a GridControl, not a bound grid. I want to lock certain rows so that they cannot be moved, and allow others to move.
HAhaneefm Syncfusion Team April 5, 2007 06:11 PM UTC
Hi Jeugenides ,
This can be achieved by handling the MouseDown event of the Grid. In that event, you need to set the AllowSelectedRows property to false for the required row in a grid. You can use the following code snippet to achieve this.
private void gridControl1_MouseDown(object sender, MouseEventArgs e) { GridControl grid = sender as GridControl; Point pt = new Point(e.X,e.Y); int row,col; if( grid.PointToRowCol( pt,out row,out col)) { if( row == 4 && col == 0) grid.AllowDragSelectedRows = false; else grid.AllowDragSelectedRows = true; } }