Nevermind, my mistake.

VB Code:
  1. Private Function CheckmyList()
  2. Dim i As Integer
  3. Dim mystr As String
  4. Dim bFound As Boolean
  5. mystr = Text6
  6. For i = 0 To List1.ListCount - 1
  7.     If InStr(UCase(List1.List(i)), UCase(mystr)) Then
  8.         MsgBox "The command has been sent, " & mystr & "!"
  9.         bFound = True
  10.         Exit For
  11.     End If
  12. Next
  13. If Not bFound Then
  14.     MsgBox "Sorry, " & mystr & " but you do not have access!"
  15. End If
  16. End Function