I have this code for application to wait until web page source is downloaded:
Please tell me if here is something wrong, and if there is another way to do this?
Code:
sub main()
Do Until downloadcomplete
Application.doevents()
Loop
end sub
Sub DownloadCompleted(ByVal sender As Object, _
ByVal e As System.Net.DownloadStringCompletedEventArgs) handles client1.DownloadstringCompleted
downloadcomplete = True
End Sub