FunctionRegExpTest(patrn,strng)
DimregEx,Matches
SetregEx=NewRegExp
regEx.Pattern=patrn
regEx.IgnoreCase=True‘為真則忽略大小寫,否則嚴格匹配大小寫
regEx.Global=True
SetMatches=regEx.Execute(strng)
RegExpTest=Matches.count
EndFunction
MsgBox(RegExpTest("is.","IS1is2IS3is4"))
新聞熱點
疑難解答