Hi all, I'm trying to use regex to take the contents of the title tag from a html page but cant get rid of the <title> tags on either side my code looks like this:
Set regEx = New RegExp regEx.IgnoreCase = True regEx.Global = True regEx.Pattern = "<title>(.*)</title>"
Set Matches = regEx.Execute(strPage) strTitle = Matches.Item(0).Value
It returns something like "<title>Best widgets</title>" and I want "Best widgets". I've seen examples with $1 in to return certain bits but am not sure how to use them outside of the replace method - can anyone help me out?