' Collection of code snippets by Arne Vajhøj 
' (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
Imports System
Imports System.Text.RegularExpressions

Namespace E
    Public Class Program
        Private Shared ReadOnly re As New Regex("<[^>]*>", RegexOptions.Compiled Or RegexOptions.Singleline)
        Public Shared Function Strip(s As String) As String
            Return re.Replace(s, "")
        End Function
        Public Shared Sub Main(args As String())
            Dim html As String = "<html>" & vbCr & vbLf & "<head>" & vbCr & vbLf & "<title>Test</title>" & vbCr & vbLf & "</head>" & vbCr & vbLf & "<body>" & vbCr & vbLf & "<h1>Test</h1>" & vbCr & vbLf & "<p>bla bla</p>" & vbCr & vbLf & "<p>mere bla bla</p>" & vbCr & vbLf & "</body>" & vbCr & vbLf & "</html>"
            Console.WriteLine(html)
            Console.WriteLine(Strip(html))
        End Sub
    End Class
End Namespace
