[Gambas-user] Gridview Select Multiple rows.

Benoît Minisini gambas at ...1...
Fri Nov 5 13:26:29 CET 2010


> Sorry, this does not work. It only applies to the ListView. I do use a
> ListView elsewhere and the easiest way is simply to loop through all
> items with the .movenext function and check for "If lvw.current.selected
> or lvw.item.selected". Then add the Key to the array of items to process.
> 
> Unfortunately the GridView has no .item property. It has a .current
> property but this does not have a .selected property.
> 
> I think I will add an extra hidden column to my grid to hold a
> 'Selected' flag. I can use some of your example to track the CONTROL and
> SHIFT keys to reset these flags as appropriate.
> Regards
> Michael
> 

You need something like that:

For iInd = 0 to TheGridView.Rows.Count - 1
  If TheGridView.Rows[iInd].Selected Then
    ...
  Endif
Next

Regards,

-- 
Benoît Minisini




More information about the User mailing list