用listbox.listcount
Private Sub Command1_Click()
Print "list1条目数为:" & List1.ListCount
Print "list2条目数为:" & List2.ListCount
Print "总条目数为:" & List1.ListCount + List2.ListCount
End Sub
Private Sub Form_Load()
For i = 0 To 10
List1.AddItem "1-" & i
Next i
For i = 0 To 20
List2.AddItem "2-" & i
Next i
End Sub