Thanx, but I am already doing that, except that I am not inserting the
WebBrowser control, but I am creating it dynamically. The event handlers
exist in my document. In fact, as far as I could tell, these were working
while I was in VS 2003 environment, but not in VS 2005 which I am using now.
Thanx,
--
Anil Gupte
www.keeninc.net www.icinema.com www.wizo.tv
"kimiraikkonen" <ki*************@gmail.comwrote in message
news:fe**********************************@k37g2000 hsf.googlegroups.com...
On Jun 9, 9:52 am, "Anil Gupe/keen inc." <anil-l...@icinema.com>
wrote:
I used the following to create a new Web Browser Control
Dim WithEvents webBrowserContent As New AxSHDocVw.AxWebBrowser
It works fine for some things for example
webBrowserContent.Navigate(url) works. However, the DocumentComplete,
NavigateComplete2 and a couple of other events I tried do not trigger when
the user navigates in that WebBrowser Control - what am I doing wrong?
Thanx,
--
Anil Guptewww.keeninc.netwww.icinema.comwww.wizo.tv
Anil,
You can use Webbrowser control, wrapped version of ShDocVw and
available in your toolbox. After placing it on your form, double-click
on it and the such events can be created like this:
' Document completed event
Private Sub WebBrowser1_DocumentCompleted(ByVal sender As
System.Object, ByVal e As
System.Windows.Forms.WebBrowserDocumentCompletedEv entArgs) Handles
WebBrowser1.DocumentCompleted
' Code here
End Sub
'Navigated event
Private Sub WebBrowser1_Navigated(ByVal sender As System.Object, ByVal
e As System.Windows.Forms.WebBrowserNavigatedEventArgs) Handles
WebBrowser1.Navigated
' Code here
End Sub
and you can find more by seeing events after "handles" clause.
Hope this helps,
Onur Güzel