Author: mmknitin | Posted on: 9/26/2008 10:10:48 PM | Views : 606

Hi, i am using the following validations for to check for special characters but in my text box i want to make some changes i.e the user should be allowed to enter letters and numbers and also i want to allow him <  > and / sign in the special characters how to change the regex i dont know so please help
if (txtScName.Text.Trim().CompareTo(string.Empty) != 0 && !System.Text.RegularExpressions.Regex.IsMatch(txtScName.Text, "^[a-zA-Z )('\\-\\/]*$"))
flag = false;
...

Go to the complete details ...