Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1028
  • Last Modified:

AxSHDocVw.AxWebBrowser error - "queryinterface for interface shdocvw.iwebbrowser2 failed"

Hi,

I have a vb.net application using webbrower control.  
I am using the following command to display html file in this browser (AxSHDocVw.AxWebBrowser)

browser.Navigate("searching.html")

I works fine, but if the application is idle for some time and when it tries to call this line again it gives an error

"queryinterface for interface shdocvw.iwebbrowser2 failed"

Please help

Thanks

0
inetworks
Asked:
inetworks
  • 2
1 Solution
 
SijinCommented:
Is the browser object going out of scope?

Can you provide the code for the method where you call this line? Make sure browser is not a local variable and is a class level variable.
0
 
inetworksAuthor Commented:
Thank you. The problem was due to a thread and it is solved now
I Put the thread inside a class and raised an event when thread is completed
to navigate a page to browser control.

Thanks
0
 
SijinCommented:
Good. :)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now