I've been trying to diagnose a bug I have with OpenFileDialog. I've now isolated the reproducability of the bug.
The bug is very simple. Click a button that is supposed to OpenFileDialog1.ShowDialog(). Instead, the program freezes. The dialog never displays. No bug is shown during Break, it's just waiting on the .ShowDialog() command to return.
Basically, my problem is this:
The only code I have in my button is:
the_url = "http://www.google.com/"
Try
WebBrowser1.Navigate(the_url)
Catch ex As Exception
MsgBox("Maybe?: " & ex.ToString)
End Try
I never do get a msgbox with an error. Any help would be appreciated. I have already confirmed that the .ShowDialog() command is always run on the main thread. I have tried to set ShowHelp = True, and no luck. I have traced the bug down to something with WebBrowser1... If anyone can help me solve this, I will totally be in love with you.
Thanks community!
I have solved this problem. The error is related to using the IE11 Emulation Control (11000). For some reason this interferes with OpenFileDialog and causes it to hang. I have no idea why. I changed my WebBrowser1 to use IE9 Emulation Control (9999) and the error has gone away. Thank you to those who looked into this. This is a registry entry in HKEY_CURRENT_USER.