here is an example from the LR… I added [+":"+str(match.SubExpressionStartB(0)))]
Dim re As New RegEx
Dim match As RegExMatch
Dim ro As New RegExOptions
ro.CaseSensitive = false
re.Options = ro
re.SearchPattern = "software"
match = re.Search("How much software can a Software Developer make?")
Dim result As String
Do
If match <> Nil Then
result = match.SubExpressionString(0)
MsgBox(result+":"+str(match.SubExpressionStartB(0)))
End If
match = re.Search
Loop Until match Is Nil
match.SubExpressionStartB(0) seems to give the START location of what was found, but how about the LENGTH?
this is a simple example looking for a specific word.
but what about something more complex…
re.SearchPattern = "(?i)(?:^|(?<= ))(one|common|word|or|another)(?:(?= )|$)"
re.SearchPattern = "[-+]?[0-9]*\\\\.?[0-9]"
ultimately I will have a textbox that it will need to apply at least 4 RegEx to