Webbrowser Stopping process on Error Message
Posted on 2005-03-31
This is a repeat question that i have asked already, however i closed it out too soon. So heres another try at it.
I have made a webbrowser that basicly goes out to the web every half hour to download data from a webpage.
Everything works great, however once and a while i get an error from the page saying "Lost SQL connection during query". When this happens my process halts and waits for a user to walk up and hit ok on the error. I have since added the webbrowser1.silent = true and i get less dialog errors. However this paticular error is not silenced using the previous.
I have also tried refrencing the internet explorer object itself using only code (no control) which the process keeps flowing when this dialog comes up (being that IE is independant of my VB, it just launches a new window on the next cycle) however i cannot get a document_complete message back when the page loads so that method isn't really useful either. (I may just be missing something altogether)
I would prefer to use the webbrowser control if i can find a way to silence or trap that error when it comes up so that my process keeps flowing. (As a temporary workaround i have vb move the mouse to the middle of the screen and send a click every half hour or so to click ok on the button) This is of course a complete hack job and i would like to handle it in a cleaner manner. I really wanted to post a screen shot of the error in the hopes that someone would relate to it beter. If anyone has any good ideas i would greatly appreciate it. (Meanwhile i fight with the site admin to get the sql errors stopped at the root, but this is a slow and painful process. Especially so close to year end) Thanks again. -Shawn