Page 1 sur 1
IsAlphaNumeric

Publié:
29 Mars 2011 à 09:16
par Michael DELIQUE
- Code : Tout sélectionner
Function isAlphaNumeric(wSource As String) As Boolean
On Error Goto CatchError
isAlphaNumeric = False
If Trim(wSource) = "" Then
Exit Function
End If
If (wSource Like "*[!a-z,!A-Z,!0-9]*") = True Then
isAlphaNumeric = False
Else
isAlphaNumeric = True
End If
Exit Function
CatchError:
Msgbox "("+Cstr(Getthreadinfo (1))+" Call by "+Cstr(Getthreadinfo(10))+")"+Chr(10)+"Erreur " + Cstr(Err) + " : "+Chr(10) + Cstr(Error)+". "+Chr(10)+"Ligne N° "+Cstr(Erl),16," ERREUR !"
isAlphaNumeric = False
Exit Function
End Function