Sub Globals
'Declare the global variables here.
End Sub
Sub App_Start
Form1.Show
If OpenDialog1.Show = cCancel Then AppClose
q = Chr(34) & Chr(34)
r = "(?:[hH][rR][eE][fF]\s*=)"
r = r & "(?:[\s"&q&"(']*)"
r = r & "(?!#|[Mm]ailto|[lL]ocation.|[jJ]avascript|.*css|.*this\.)"
r = r & "(.*?)(?:[\s>)"&q&"'])"
Regex.New2(r,true,true)
FileOpen(c1,OpenDialog1.File,cRead)
s = FileReadToEnd(c1)
FileClose(c1)
Match.New1
Match.Value = regex.Match(s)
Do While Match.Success
lstLinks.Add(Match.GetGroup(1))
Match.Value = Match.NextMatch
Loop
End Sub
thank you, the regex works great, but i took the "bracket exception" or whatever I should call it out, because it gave my trouble with links like "gnfgn (1)"