【C#】去除字符串中的空格,回车,换行符,制表符

string l_strResult =  str.Replace("\n", "").Replace(" ","").Replace("\t","").Replace("\r","");

猜你喜欢

转载自blog.csdn.net/u010398722/article/details/80536331