0
I have a list ListBox1
in a userform configured for multiple item selection. There is some function, statement, or way to return the number of selected items?
0
I have a list ListBox1
in a userform configured for multiple item selection. There is some function, statement, or way to return the number of selected items?
2
I believe that code should help you.
Dim intIndex As Integer
Dim intCount As Integer
With ListBox1
For intIndex = 0 To .ListCount - 1
If .Selected(intIndex) Then intCount = intCount + 1
Next
End With
Label1.Caption = "Selecionados " & intCount & " de " & ListBox1.ListCount
Browser other questions tagged excel vba userform listbox excel-vba
You are not signed in. Login or sign up in order to post.
Thanks, @andrepaulo. It works! But it only has to run a loop anyway?
– J. L. Muller
to what I know. That’s it. ...
– andrepaulo