Click here to Skip to main content
15,892,059 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I need to change IE version, they told me I have to do it in the registry during install, I have no idea how to modify the install.

What I have tried:

I put a web browser control on a win form and navigate it to translate.google.com, it used to work but stopped working on the new design of their website!
Posted
Updated 29-Dec-18 6:45am
Comments
Dave Kreskowiak 30-Dec-18 12:30pm    
That depends entirely on the app you're using to build the installer, which you didn't mention.
john1990_1 30-Dec-18 12:33pm    
I fixed the issue without learning how-to and resorting to change the installer.

Utilizing a browser control and navigating to the translate page is the problem itself:
1. It is relying on your web browser (which can change as you have found out)
2. It also relies on the web page being returned from Google (which also can change)
3. Possible violations of Google's Terms Of Service.

The best thing to do would be to utilize the Translate API and adjust your form accordingly to your needs.
Cloud Translation API documentation  |  Cloud Translation API  |  Google Cloud[^]
 
Share this answer
 
Comments
BillWoodruff 30-Dec-18 0:46am    
+5
Dave Kreskowiak 30-Dec-18 12:32pm    
Yeah, we've been around this block with the OP lots of times. Using the API is simply out of the question for him for some unknown reason.

He REALLY wants to do it the hard way.
john1990_1 30-Dec-18 12:35pm    
My program works awesomely now with Google Translate page, thank you for trying to help, I've seen a program of API and it's nothing like Google Translate page, also one can log in with his Google account and save history of translations and can also star translations, I'm good, in the first place I would have to pay for a Google's API don't I?
Dave Kreskowiak 30-Dec-18 12:48pm    
Pay for it? Not really. It depends on how many requests you make in a month and under what circumstances.

If this is going to be a "commercial" application, then you have no choice but to use the API because your app is violating Google's terms of service for the web site.

Google Terms of Service[^]

Using the translate API never free.
Pricing - Cloud Translation API[^]

FAQ - Cloud Translation API[^]
john1990_1 30-Dec-18 12:50pm    
The program is not commercial, and I open Google Translate page in a web browser just like Edge or Firefox, it's just that the browser is brought to front when the user presses F1.
This works like magic, I've had a sad time when Google Translate stopped working and this could have fixed it, I didn't have my program for a long time for a stupid reason.

To get the WebBrowser control to show modern contents:

The WebBrowser control uses the same Internet Explorer version which is installed on your OS but it doesn't use the latest document mode by default and shows content in compatibility mode.

As a symptom, you can see the site in Internet Explorer, but WebBrowser control doesn't show the site correctly and for some sites it shows script error too.

Solution:

You can tell the WebBrowser control to use the latest document mode without compatibility mode in WebBrowser control. You can follow instructions here to disable the setting using registry.

This sets document mode in version in IE the current process to 99999 which means the maximum version.

var appName = System.Diagnostics.Process.GetCurrentProcess().ProcessName + ".exe";

using (var Key = Registry.CurrentUser.OpenSubKey(@"SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION", true))
{
   Key.SetValue(appName, 99999, RegistryValueKind.DWord);
}

What Happens if I Set the FEATURE_BROWSER_EMULATION Document Mode Value Higher than the IE Version on the Client?

Obviously, the browser control can only support a document mode that is less than or equal to the IE version installed on the client. Using the FEATURE_BROWSER_EMULATION key works best for enterprise line of business apps where there is a deployed and support version of the browser. In the case you set the value to a browser mode that is a higher version than the browser version installed on the client, the browser control will choose the highest document mode available.
 
Share this answer
 
v7
Comments
BillWoodruff 30-Dec-18 0:50am    
It's opaque to me what this does; why don't you write a Tip/Trick here describing what it does so other people can benefit ?
john1990_1 30-Dec-18 8:35am    
Sure, I edited the answer, is it clear now?
BillWoodruff 30-Dec-18 16:04pm    
Yes, that's very clear, and I think it will make a great tip-trick that will be useful to others. Do you want some help posting that as Tip/Trick ?

cheers, Bill
john1990_1 30-Dec-18 16:09pm    
Yes.
BillWoodruff 1-Jan-19 19:34pm    
It's easy to post a tip/trick: see this for info on getting started, and let me know how it goes; be happy to help if you need it.cheers, Bill

https://www.codeproject.com/Messages/3123931/Note-From-Code-Project-The-Article-Writing-Forum.aspx

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900