使用 变量.Replace(@“\0”,"") string str="abcde\0\0\0\0\0\0"; str=str.Replace(@"\0",""); str的结果是abcde。 相关文章: 2021-08-17 2021-10-24 2022-12-23 2022-12-23 2022-12-23 2022-12-23