/ Published in: Visual Basic
This method checks whether a ListBox contains a certain item (based on its text).
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
Public Function isFoundInListbox(list As listbox, item As String) as Boolean Dim i As Long For i = 0 To list.ListCount - 1 If (list.ItemData(i) = item) Then isFoundInListbox = True Exit Function End If Next i isFoundInListbox = False End Function