Hi
I have a grid which I need to select multiple rows and process the contents of each rows cells
I have tried looping through the rows in the grid and checking the grid.Rows(i).Activated = true
but this only returns the first Active row in the grid.
Is there another property which distinguishes selected rows from non selected rows ??
Is there a difference between active and selected rows
Thanks
Colm
Each row has a property named "Selected".
Active row is the row that has the input focus, hence there is only one active row. Selected row is a row that was selected by the user or by code and there could be more than one.
If you want to get all selected rows use grid.Selected.Rows
If you want to select all rows, don't go over them and set Selected = true because this can be very slow, but use grid.Selected.Rows.AddRange(grid.Rows)
Thanks for the help
I just implemented the suggestion for selected rows but when I select several rows the grid.Selected.Rows returns zero rows
Is there some other property that needs to be set on the grids to allow multiple row selection
I wanted to get the rows that are selected and edit the cells only in grid but not entrie grid. Please help me. I am not able to get selected rows, its is displaying is 0
if
(BaseGrid.ActiveRow != null)
{
foreach(UltraGridRow row in BaseGrid.Rows)
if (row.Selected)
row.Activation =
Activation.AllowEdit;
}
You need to set the SelectTypeRowDefault property before you select the rows.
grid.DisplayLayout.SelectTypeRowDefault =
SelectType.Extended;
grid.DisplayLayout.Rows[0].Selected = true;
grid.DisplayLayout.Rows[1].Selected = true;
May be you have set the (UltraGrid Object).DisplayLayout.Override.SelectTypeRow property to select single row only.
Have a look at the options this provides.
I got my grid to do multiple selection by setting the property to the following value : Infragistics.Win.UltraWinGrid.SelectType.ExtendedAutoDrag
Hello,
I have the same Issue by selecting rows from an UltraGrid.
I tried to implement this example on the following site: How to Drag and Drop Rows in a Grid
If the DragDrop event is fired, the program get no selected rows. The object of type SelectedRowsCollection has zero values.
I had opened the UltraWinGrid Designer from the grid's smart tag and selected the "Feature Picker" and used the "Selection" node.
I use VS2008 and Infragistic 9.2. I spent much time get the issue solved, but I see no solution.
Hi,
I have seen the same thing. We have a made a derived grid from UltraWinGrid 7.3 and when we reload the grid and there is a selected row all the rows after the datasource has been reloaded appears to be selected but the selected.Rows property is empty.