vendredi 1 juillet 2016

How to find out the amount of selected checkboxes/items in ListView (VBA)

Is there anyone who knows how can I find out the number of selected items in a ListView with checkboxes especially in VBA?

My approach is as follows. When I click on a Checkbox in this ListView then the application have to check if the selected items are more than three then throw an error message.

Private Sub ListView1_ItemCheck(ByVal Item As MSComctlLib.ListItem)
    If checked items > 3 then
         //Error message
    Else
         //continues
    End If
End Sub




Aucun commentaire:

Enregistrer un commentaire