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