1 public static bool ContainsChinese(string text) 2 { 3 if (string.IsNullOrEmpty(text)) 4 return false; 5 string pattern = "[u4e00-u9fbb]"; 6 return Regex.IsMatch(text, pattern); 7 }
1 public static bool ContainsChinese(string text) 2 { 3 if (string.IsNullOrEmpty(text)) 4 return false; 5 string pattern = "[u4e00-u9fbb]"; 6 return Regex.IsMatch(text, pattern); 7 }