timer in VB?

Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Mar 2008
Posts: 16
Reputation: mykar_88 is an unknown quantity at this point 
Solved Threads: 0
mykar_88 mykar_88 is offline Offline
Newbie Poster

timer in VB?

 
0
  #1
Jul 5th, 2008
hi
how to make the process sleep until my webbrowser gets loaded.
this is my code


webbrowser1.navigate("www.google.co.in")
text=webbrowser1.document.body.innertext



pls send me the code
Reply With Quote Quick reply to this message  
Join Date: Feb 2008
Posts: 509
Reputation: selvaganapathy is an unknown quantity at this point 
Solved Threads: 88
selvaganapathy's Avatar
selvaganapathy selvaganapathy is offline Offline
Posting Pro

Re: timer in VB?

 
0
  #2
Jul 5th, 2008
Use BeforeNavigate Event and NavigateComplete Event.

Ex.
Draw a Command Button (Command1) and PictureBox (Picture1)
Draw WebBrowser Control (WebBrowser1) inside PictureBox

Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. Private Sub Command1_Click()
  2. WebBrowser1.Navigate ("www.google.co.in")
  3. End Sub
  4.  
  5. Private Sub WebBrowser1_BeforeNavigate2(ByVal pDisp As Object, URL As Variant, Flags As Variant, TargetFrameName As Variant, PostData As Variant, Headers As Variant, Cancel As Boolean)
  6. Picture1.Enabled = False
  7. End Sub
  8.  
  9. Private Sub WebBrowser1_NavigateComplete2(ByVal pDisp As Object, URL As Variant)
  10. Picture1.Enabled = True
  11. End Sub

Instead of PictureBox u can use Frame Control
Last edited by selvaganapathy; Jul 5th, 2008 at 11:21 pm.
KSG
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Visual Basic 4 / 5 / 6 Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC