We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Set selection mode for a row

Thread ID:

Created:

Updated:

Platform:

Replies:

34651 Sep 14,2005 08:10 AM UTC Sep 14,2005 02:18 PM UTC WinForms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On September 14, 2005 08:10 AM UTC

Hi together, I have gridcontrol and I want to set for a special row that no cell in this row can''t be selected not even the whole row. How can this be done programmatically? Kind regards, Franz

Administrator [Syncfusion]
Replied On September 14, 2005 02:18 PM UTC

Hi Franz, You can easily prevent a row from being selected using the SelectionChanging event, and cancelling it if the a particular row is in the selections. Below is a little snippet. But this will just stop the selection at that row. You would not be able to continue dragging and select other rows on the opposite side of the currently selected rows. private void gridControl1_SelectionChanging(object sender, Syncfusion.Windows.Forms.Grid.GridSelectionChangingEventArgs e) { // For row 3. if(e.Range.IntersectsWith(GridRangeInfo.Row(3))) e.Cancel = true; } Regards, Leo.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;