Validate text using RegEx
‘Email address:
Regex.IsMatch(Me.txtEmail.Text, “w+([-+.’]w+)*@w+([-.]w+)*.w+([-.]w+)*”)
‘Alpha-numeric (no space):
Regex.IsMatch(Me.txtUsername.Text, “^[0-9a-zA-Z]+$”)
‘Alpha-numeric with space, at least 5 chars:
Regex.IsMatch(Me.txtUsername.Text, “[0-9a-zA-Z’ ‘]{5,} )