Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Winform webbrowser reCAPTCHA doesn't show

I create a Winform application, when i use webbrowser.

My problem, when i navigate to the site, the reCAPTCHA doesn't show. I got an error message my webbrowser doesn't support, i should update.

If i know right, the winform webbrowser work from IE what we have got in our computer.

My computer has got IE 11. I tried check this website with my IE, and ther the reCAPTCHA working perfectly.

How can i solved this problem? I want show the reCAPTCHA in my build in webbrowser in my winform.

like image 319
Misland Avatar asked Jul 05 '16 13:07

Misland


1 Answers

The version of the WebBrowser is the problem:

The only thing that you need to do is to set the version of the browser in the key registry:

Something like this will do the job:

var appName = System.IO.Path.GetFileName(System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName);
                Microsoft.Win32.Registry.SetValue(@"HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION",
                      appName, 11000, Microsoft.Win32.RegistryValueKind.DWord);

    //where: 11000 is currently the last version of iExplorer

Please note that 11000 is the value that worked(for me). If you use 10000 or lower it is not going to work.

like image 197
Ayorus Avatar answered Sep 18 '22 11:09

Ayorus