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. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Select Row

Thread ID:





7491 Sep 26,2003 03:43 PM UTC Dec 11,2003 08:52 AM UTC WinForms 6
Tags: GridControl
Administrator [Syncfusion]
Asked On September 26, 2003 03:43 PM UTC

This should be an easy question, but for some reason I can't get Grid to do this. I want the entire row to be selected (highlighted) whenever a cell is selected. How can I do this? Thanks, Greg

Administrator [Syncfusion]
Replied On September 26, 2003 04:31 PM UTC

There are two solutions: a) ListBox mode Set grid.ListBoxSelectionMode = SelectionMode.One, and also handle the grid.CurrentCellActivating event and just set e.ColIndex = 0 in your handler. b) Check out also the sample D:\Syncfusion\Essential Suite\Grid\Samples\Quick Start\HighlightCurrentRow (using PrepareViewStyleInfo) Stefan

Sajid Mohammed
Replied On September 29, 2003 12:14 PM UTC

Stephen, i am using ListBoxSelectionMode to get the row select behavior into my GridControl. is it possible to get the row selection done with a different color? the default row select color is too dim and the row doesnt really appear selected.

Administrator [Syncfusion]
Replied On September 29, 2003 06:15 PM UTC

The GridModelOptions.AlphaBlendSelectionColor property specifies the System.Drawing.Color for alpha blended cell selections. There you could change the color used for selections. Stefan

Administrator [Syncfusion]
Replied On September 30, 2003 04:28 PM UTC

Thanks Stefan.

Replied On December 11, 2003 02:36 AM UTC

Hi Guys... In a Virtual Grid, I put the code in to select the entire row and it works fine..but how do I programattically set the highlighted row to any visible row? how do I know what the top row is and the bottom row is and move the hightlight bar within the visible rows? Thanks. Dave

Administrator [Syncfusion]
Replied On December 11, 2003 08:52 AM UTC

Top visible row is this.grid.TopRowIndex. Bottom visible row is this.grid.ViewLayout.LastVisibleRow. To move the the current cell (hence the current row), you call this.grid.CurrentCell.MovetTo.


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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

Live Chat Icon For mobile
Live Chat Icon