Dim d As Integer
For d = 0 To TextBox2.Text
WebBrowser1.Navigate(TextBox1.Text)
//a code that pauses the loop but does not stop the browser thread
Next d
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
I'm not sure if the browser is rendering on a separate thread. If it is then the following should work:
System.Threading.Thread.Sleep(3000) ' Sleep for 3 seconds
If the browser control is rendering on the same thread as your application then you will have to refactor the code to utilize a timer as Thomas L suggested.