Private Sub WebBrowser1_NewWindow2(ppDisp As Object, Cancel As Boolean)Cancel = TrueWebBrowser1.Navigate2 (WebBrowser1.Document.activeElement.href)End Sub