如何用replace()将 ' 替换成 \' 用replace将 ' 替换成 \' 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 string a = "aaaaaa'dddddd";Response.Write(a.Replace("'","\\'")); ' '是不允许空字符的。[string].Replace(" ",@"\"); string txt="this is it's tail.";txt=txt.Replace("'","\\'");\是特殊符号,要使用\来进行转义。 string a = "'wer'wer'wer'"; a= a.Replace("'", "\\'"); Response.Write(a); Response.Write(a.Replace("'","\\'")); string str = @"'\'\'\";str.Replace("'", @"\'") string str = @"an'd'yba'ng'sff";str.Replace("'", "\\"); VS自定义控件无法在工具箱中显示 怎样用C#语言在winform窗体应用程序中实现三次登陆程序失败程序自动退出的功能 c# 创建类(.cs) 关于用户自定义控件 winform 里面怎么用textbox 显示数据库中查询出来的列啊? 如何将excel数据高效率导入oracle?在线等! 哪有CRYSTAL REPORTS 9水晶报表设计与开发大全(中文) 的电子版呀 ■求助■如何用,c#实现聊天室?■■■ C#的底层用什么写的 求下载地址 ICSharpCode.SharpZipLib.dll 关于播放AVI文件的问题 如何让c# windows程序 定时启动或者一直运行正常(着急)
string a = "aaaaaa'dddddd";
Response.Write(a.Replace("'","\\'"));
[string].Replace(" ",@"\");
txt=txt.Replace("'","\\'");
\是特殊符号,要使用\来进行转义。
string a = "'wer'wer'wer'";
a= a.Replace("'", "\\'");
Response.Write(a);
string str = @"'\'\'\";
str.Replace("'", @"\'")
str.Replace("'", "\\");