过滤汉字

Regex.Replace(inputStr,@"[\u4e00-\u9fa5]",string.Empty);

  

提取汉字:

Regex.Replace(inputStr,@"[^\u4e00-\u9fa5]",string.Empty);//注意这里多了个^符号

  

 

相关文章:

  • 2022-01-07
  • 2022-03-01
  • 2022-01-03
  • 2022-12-23
  • 2022-01-12
  • 2021-05-19
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-11-13
  • 2022-02-07
  • 2021-12-03
  • 2021-12-09
相关资源
相似解决方案