Guest User

Untitled

a guest
Apr 19th, 2018
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.31 KB | None | 0 0
  1. Regex alphanum = new Regex("[^a-zA-Z0-9]");
  2.  
  3.             if (alphanum.IsMatch(username.Text))
  4.             {
  5.                 errortext.Text = errortext.Text + "</br>" + "Username must only consist of alphanumeric characters.";
  6.                 errortext.Visible = true;
  7.                 didFail = true;
  8.             }
Add Comment
Please, Sign In to add comment