-
There's a list with internet-addresses.
My program starts a browser (as many times as there are items
in the listbox) and opens all the adresses
from this list.
But it could be that the page isn't found on this server / adress and
theres's an (internet) error 404.
Is it possine, that my programm closes all the Browser-windows
in which the internet error 404 occured ? When there's
no error the page should load normal.
Matt ;)
-
Code:
Option Explicit
Private Sub Form_Load()
'the file your navigating to from your list
WebBrowser1.Navigate App.Path & "\test.htm"
DoEvents
End Sub
Private Sub Timer1_Timer()
Static Toggle As Boolean
If Not Toggle Then
buf = WebBrowser1.Document.Title
If buf <> "" Then
Me.Caption = buf
buf = LCase(buf)
If InStr(buf, "cannot find server") <> 0 Then End
End If
End If
End Sub
this works, but you need to tidy up the closedown of the window, as i've just put end, but you may wish to relase resources etc.
DocZaf
{;->