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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

selecting grid ranges

Thread ID:





35597 Oct 4,2005 09:18 PM UTC Oct 6,2005 07:10 PM UTC WinForms 7
Tags: GridControl
Anthony Avella
Asked On October 4, 2005 09:18 PM UTC

Hi. I''m currently using grid version What do I need to do to allow my user to select multiple rows (range) in the grid? Also, how can I capture that range in my code and use those values for various processes? thx

Administrator [Syncfusion]
Replied On October 4, 2005 09:55 PM UTC

set grid.ListBoxSelectionMode = SelectionMode.MultiSelect; To go through the selected rows, see this KB. http://www.syncfusion.com/support/kb/grid/Default.aspx?ToDo=view&questId=261

Anthony Avella
Replied On October 5, 2005 01:16 PM UTC

Worked great. Thx!!!

Administrator [Syncfusion]
Replied On October 6, 2005 05:37 PM UTC

This selection mode selects whole rows. Is there a way to allow users to select cells at a time (using, shift, ctrl with arrows, etc..) or whole columns at a time vs whole rows at a time? thx

Administrator [Syncfusion]
Replied On October 6, 2005 05:41 PM UTC

Try setting: grid.ListBoxSelectionMode = SelectionMode.None and then set grid.AllowSelections = GridSeelctionFlags.Any. This should allow you user to select rows, columns or cells. You can control exactly what is selectable by adjusting the flags in grid.AllowSelections.

Administrator [Syncfusion]
Replied On October 6, 2005 06:05 PM UTC

But this line of code: list = QuoteGrid.Selections.GetSelectedRows(true, false); gives me a 0 list.count, meaning I haven''t selected anything, and this loop: foreach(GridRangeInfo range in list) won''t work. Basically, I need the user to be able to select any range of cells on the grid and I need to see that range from QuoteGrid.Selections.GetSelectedRows Can we do this?

Administrator [Syncfusion]
Replied On October 6, 2005 06:36 PM UTC

If you are not selecting rows, then GetSelectedRows will not return anything. You need to use another method, GetSelectedRanges. See this KB. http://www.syncfusion.com/support/kb/grid/Default.aspx?ToDo=view&questId=280

Administrator [Syncfusion]
Replied On October 6, 2005 07:10 PM UTC

Awesome Thanks!!!!


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