Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Wait for WebBrowser1.Naviage to Load into History

Status
Not open for further replies.

lfast

IS-IT--Management
Apr 16, 2002
16
0
0
US
This works partially:

For i = 1 To total ' where total is the last page
txtURL.Text = link(i) ' navigate to each respective link
WebBrowser1.Navigate (txtURL.Text)
Do
DoEvents
Loop Until WebBrowser1.Busy = False ' wait until load
' finishes and
' goes to history
Next i

However, it stops... and I have to hit my <next> button,
or hit the <update> button on the server's webpage for
it to continue .


How can I make it more efficient so that it will go to
the last page without stopping... Does anybody know why
it would stop.. I would think this would be a common
problem..

Thank you,

David
 

Have you ever seen WB.Busy = False? Search this site in your forums for 30 days (or more) for all words with webbrowser and you should find some other examples.

Good Luck

 
Could not find the information... Did searches for webbrowser, web browser, WB.busy, etc...

 
The default search period is now 7 days - you need to go to advanced search to set duration.

Webbrowser produced 88 hits for me on 6 month setting
________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first

'People who live in windowed environments shouldn't cast pointers.'
 
I wanted you guys to know that I figured out this problem... It came up again in another program I had to write...

I did read the posts here about it,.. they were basically what I had already tried... which was using the

do while webbrowser1.busy=true
doevents
loop

and similar statements.. What finally worked was this...

Option Explicit
dim wait as boolean

Wait=true
Do While wait = True
DoEvents
Loop

Private Sub WebBrowser1_NavigateComplete2(ByVal pDisp As Object, URL As Variant)
wait = False
End Sub


Hope this helps others with a similar problem.. this has to be very common.. The webbrowser would navigate to the next page.. and then the next... and then stop.... instead of continuing through the list of pages...

Sincerely,

David
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top