【发布时间】:2020-07-17 04:45:35
【问题描述】:
所以,我需要将这个字符串 " ' " (空白空格)替换为 ',而 .Replace() 是 ovios 的方式,但是当我试着做
-
txtAux = txtAux.Replace(" "'" " , "");
第三个 " 没有像我预期的那样表现。 我尝试做一些我有时在 .Split 上做的事情...
-
txtAux = txtAux.Replace(new string { " "'" "},new string {"'"});我也尝试使用正则表达式,但我不喜欢使用正则表达式。
我有这个:'"' CHARSET '"'|''' CHARSET ''' 我需要这个:"CHARSET"|'CHARSET'
【问题讨论】:
标签: c# string replace regexp-replace quotation-marks