以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  怎么替换 / 为 \  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=76590)

--  作者:jinzhengbe
--  发布时间:2015/11/1 22:40:00
--  怎么替换 / 为 \

If Tables("qt").Current.IsNull("bbb") Then

Else
 e.DataRow("pic")="c:\\pic\\补货\\" & e.DataRow("bbb")

End If


If Tables("qt").Current.IsNull("pic") Then
Else
Dim s As String =e.DataRow("pic")
s = s.Replace("/","\\")
End If
 
想在生成pic 内容后,替换pic中的 /  为 \\

 

但是不太好用,请各位指点一下


--  作者:e-png
--  发布时间:2015/11/1 23:28:00
--  
什么叫不太好用? 不明白呢
--  作者:大红袍
--  发布时间:2015/11/2 9:27:00
--  

Dim s As String =e.DataRow("pic")
s = s.Replace("/","\\")

 

改成

 

e.DataRow("pic") = e.DataRow("pic").Replace("/","\\")