View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
John John is offline
external usenet poster
 
Posts: 2,069
Default Test for no listbox selection

I have a userform w/ a listbox that has a few items. How do I test to be
sure at least one item is selected when OK is clicked. None of the following
will display the MsgBox to find the omision of listbox selection:
If Len(Listbox1) = 0 Then MsgBox "..."
If IsEmpty(Listbox1) Then MsgBox "..."
If Listbox1 = "" Then MsgBox "..."
How do I tell if no selection has been made?

I appreciate your help, -John