unhighlighting selected rows

hi,
i am using grid grouping control and i am selecting rows by clicking on row header .
So rows are getting highlighted.But now i want to deselect highligted rows in one step process by clicking n any cell .let me know what to do.

1 Reply

JS Jeba S Syncfusion Team September 4, 2007 06:51 AM UTC

Hi swaminath,

Thank you for posting query to us.

You can handle the TableControlCellClick event and deselect the highlighted row using SelectedRecords.Clear.


void gridGroupingControl1_TableControlCellClick(object sender, Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCellClickEventArgs e)
{
if (e.Inner.RowIndex > 0 && e.Inner.ColIndex>0)
{
this.gridGroupingControl1.Table.SelectedRecords.Clear();
}
}


Please refer the sample which implements the above said feature:
http://websamples.syncfusion.com/samples/Grid.Windows/F67862/main.htm

Kindly let us know if you need any further assistance.

Best Regards,
Jeba.

Loader.
Up arrow icon