JJ
Jisha Joy
Syncfusion Team
May 1, 2008 09:41 AM UTC
Hi Raul,
Thank you for posting query to us.
This can be achieved by handling the PrepareViewStyleInfo event and conditionally set ReadOnly to specific Columns.
Please refer the code:
this.gridDataBoundGrid1.PrepareViewStyleInfo += new Syncfusion.Windows.Forms.Grid.GridPrepareViewStyleInfoEventHandler(gridDataBoundGrid1_PrepareViewStyleInfo);
void gridDataBoundGrid1_PrepareViewStyleInfo(object sender, Syncfusion.Windows.Forms.Grid.GridPrepareViewStyleInfoEventArgs e)
{
if (e.ColIndex == 2 || e.ColIndex == 4)
{
e.Style.ReadOnly = true;
}
}
Regards,
Jisha