Utility/UIHelper.cs
@@ -371,15 +371,17 @@ } } private const string SPECIAL_CHA = " ()()@!#$%^&*[]|_"; static Regex s_SpecialCharacterRegex = new Regex("[ ()()@!#$%^&*[]|_]"); static Regex s_AsciiCharacterRegex = new Regex("[\x00-\x2F]|[\x3A-\x40]|[\x5B-\x60]|[\x7B-\x7E]"); public static bool HasSpecialCharac(string str) { foreach (char c in SPECIAL_CHA) if (s_SpecialCharacterRegex.IsMatch(str)) { if (str.Contains(c)) { return true; } return true; } if (s_AsciiCharacterRegex.IsMatch(str)) { return true; } return false; }