listbox isempty

Talk2Tom11

Centurion
Joined
Feb 22, 2004
Messages
144
Location
Westchester, NY
I want to be able to check if a listbox is empty... and then if it is do someone accordingly.

But i can't find something like a .isempty. How would i check to see if the listbox is empty?

in VB. :cool:
 
Yep like He said the .count. However to check it then doing something would require a statement .... you can do this several ways but as to your question you said if it is then do something so we will use an If statement

Visual Basic:
   If listbox1.items.count = 0 Then
    ' Do something
   End If

That should get it done!

vbMarkO
 
Back
Top