Mutiple selection with Checkboxes

Mar 21, 2014 at 10:23 PM

I have a column with checkboxes in sourceGrid.
How to make a selection of few rows simultanously?

very thank for your help

Apr 3, 2014 at 1:28 PM
I find a solution

Private Sub Grid1_MouseUp(sender As Object, e As MouseEventArgs) Handles Grid1.MouseUp
    Dim selRegion As SourceGrid.RangeRegion = Grid1.Selection.GetSelectionRegion()
    Dim selRows As Integer() = selRegion.GetRowsIndex()
    Dim selCols As Integer() = selRegion.GetColumnsIndex()
    If UBound(selCols) > 0 Then Exit Sub
    If UBound(selRows) = 0 Then Exit Sub
    If selCols Is Nothing Or selRows Is Nothing Then Exit Sub
    If selCols(0) <> 3 Then Exit Sub
    For i = selRows(0) To selRows(UBound(selRows))
        If Grid1(i, 3).Value = True Then
            Grid1(i, 3).Value = False
            Grid1(i, 3).Value = True
        End If
    Next i

End Sub