Unreliable WebBroser control
-
Hi, I host a WebBrowser control in a WinForm. When the user clicks a button I call Navigate(url) on the control, but it's not 100% reliable. Sometimes the control will navigate to the page, but sometimes it won't, for exactly the same URL. Has anyone seen something similar? thanx
-
Hi, I host a WebBrowser control in a WinForm. When the user clicks a button I call Navigate(url) on the control, but it's not 100% reliable. Sometimes the control will navigate to the page, but sometimes it won't, for exactly the same URL. Has anyone seen something similar? thanx
I would imagine this means that there's events being fired by the control and sometimes you're in sync with them, and some times not. You should look at what state change events the control fires and see if you can detect a pattern between those and when your code works or not. The control should work just fine.
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
-
I would imagine this means that there's events being fired by the control and sometimes you're in sync with them, and some times not. You should look at what state change events the control fires and see if you can detect a pattern between those and when your code works or not. The control should work just fine.
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
I'm not sure what you mean. I call webControl1.Navigate("www.amazon.com"); on every button click. Sometimes it works, sometimes it doesn't.
-
I'm not sure what you mean. I call webControl1.Navigate("www.amazon.com"); on every button click. Sometimes it works, sometimes it doesn't.
Well, the control works, so one assumes that it must sometimes be in a state where you have to wait before you navigate.
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.