Block edit mode on cell level

Hi,
Is it possible to block the possibiity to enter edit mode on cell level?

Regards,
ToDo


1 Reply

AD Administrator Syncfusion Team March 18, 2008 07:01 PM UTC

Hi,

Thank you for using Syncfusion products

you can able to cancel the edit mode by use of below code snippet.

GridGroupingControl
-------------------
void gridGroupingControl1_TableControlCurrentCellStartEditing(object sender, GridTableControlCancelEventArgs e)
{
int col= e.TableControl.CurrentCell.ColIndex;
int row = e.TableControl.CurrentCell.RowIndex;
if (col == 3 && row == 3)
{
e.Inner.Cancel;
}
}

GridControl & GridDataBoundGrid
-------------------------------
void Grid1_CurrentCellStartEditing(object sender, CancelEventArgs e)
{
GridCurrentCell cc = this.gridDataBoundGrid1.CurrentCell;

int col = cc.ColIndex;
int row = cc.RowIndex;
if (col == 3 && row == 3)
{
e.Cancel;
}

}

Please let me know if you need any assistance

Best regards,
Johnson



Loader.
Up arrow icon