Permalink
Fetching contributors…
Cannot retrieve contributors at this time
20 lines (17 sloc) 524 Bytes
' Visual Basic .NET Document
Option Strict On
' <Snippet1>
Imports System.Text.RegularExpressions
Module Example
Public Sub Main()
Dim input As String = "needing a reed"
Dim pattern As String = "e{2}\w\b"
For Each match As Match In Regex.Matches(input, pattern)
Console.WriteLine("{0} found at position {1}", _
match.Value, match.Index)
Next
End Sub
End Module
' The example displays the following output:
' eed found at position 11
' </Snippet1>