0
我想从0x00删除所有控制字符到0x1F。以编程方式删除字符串中的控制字符
我想我会那样做:
string x = "\x1BTEST";
for (string stringHex = "00"; !stringHex.Equals("1F"); stringHex = (int.Parse(stringHex, System.Globalization.NumberStyles.HexNumber) + 1).ToString("X2"))
{
x = x.Replace("\\x" + stringHex, "");
}
双逃避打击它。好。但怎么做呢?
[从删除字符串中的隐藏人物]的可能的复制(http://stackoverflow.com/questions/15259275/removing-hidden-characters-from-within-strings ) – MethodMan