newasp中main类(68)
Public Function CutMatchContent(ByVal str, ByVal start, ByVal last, ByVal Condition)
Dim Match,s,re
Dim FilterStr,MatchStr
Dim strContent,ArrayFilter
Dim i, n,bRepeat
If Len(start) = 0 Or Len(last) = 0 Then Exit Function
On Error Resume Next
MatchStr = "(" & CorrectPattern(start) & ")(.+?)(" & CorrectPattern(last) & ")"
Set re = New RegExp
re.IgnoreCase = True
re.Global = True
re.Pattern = MatchStr
Set s = re.Execute(str)
n = 0
For Each Match In s
If n = 0 Then
n = n + 1
ReDim ArrayFilter(n)
ArrayFilter(n) = Match
Else
bRepeat = False
For i = 0 To UBound(ArrayFilter)
If UCase(Match) = UCase(ArrayFilter(i)) Then
bRepeat = True
Exit For
End If
Next
内容版权声明:除非注明,否则皆为本站原创文章。