Function ValidateRegularPattern_FN(str_Pattern, str_Value)
Err.Clear
Dim regEx, Match
Set regEx = New RegExp ' Create a regular expression.
regEx.Pattern = str_Pattern ' Set pattern.
regEx.IgnoreCase = True ' Set case insensitivity.
regEx.Global = True ' Set global applicability.
Match = regEx.Test(str_Value) ' Execute search.
ValidateRegularPattern_FN = Match
Err.Clear
End Function
Err.Clear
Dim regEx, Match
Set regEx = New RegExp ' Create a regular expression.
regEx.Pattern = str_Pattern ' Set pattern.
regEx.IgnoreCase = True ' Set case insensitivity.
regEx.Global = True ' Set global applicability.
Match = regEx.Test(str_Value) ' Execute search.
ValidateRegularPattern_FN = Match
Err.Clear
End Function
No comments:
Post a Comment