vb regexp 正则表达式问题
我用的是vb6,如下是我的代码,期望结果是a="WWW-WW-W",b="-L-LL-",但实际得到的结果不是这样的,求高手帮忙解决一下
Dim a, b As String
Set obj = CreateObject("vbscript.regexp")
obj.ignorecase = True
obj.Global = True
obj.Pattern = "L."
a = obj.Replace("WWWLLLWWLLW", "-")
MsgBox a
Set obj1 = CreateObject("vbscript.regexp")
obj1.ignorecase = True
obj1.Global = True
obj1.Pattern = "W."
b = obj1.Replace("WWWLWWLLW", "-")
MsgBox b
万分感激
[解决办法]
L+才对