Navigation in the same window for WebBrowser Control
-
I need to know how to keep the navigation in the same window using the WebBrowser Control. It's NewWindow event does not have the URL in it. I read about SHDocVw.WebBrowser_V1, interface, which has a better NewWindow event, but I don't know how to make the cast from the WebBrowser control in C#. I've noticed that the msdn article on this is in VB. Thanks.
-
I need to know how to keep the navigation in the same window using the WebBrowser Control. It's NewWindow event does not have the URL in it. I read about SHDocVw.WebBrowser_V1, interface, which has a better NewWindow event, but I don't know how to make the cast from the WebBrowser control in C#. I've noticed that the msdn article on this is in VB. Thanks.
If you are using Windows XP SP2 you should check into a new event that has been defined, DWebBrowserEvents2::NewWindow3 Event[^]. You will want to check the
dwFlags
which will be a NWMF[^] enumeration. This should get you started. - Nick Parker
My Blog | My Articles