1

This is a newbie question about what is the version of the built-in webBrowser engine in visual studio 2012, it says 4.5.0 or something but i mean corresponding to Internet Explorer versions, is it IE 8, 9 or 10.

and if it is IE 8 or 9, is it possible to embed some other browser engine like Chrome or Firefox?

Thanks in advance.

Mi-Creativity
  • 9,554
  • 10
  • 38
  • 47
  • don't have VS2012 but you can easily find out yourself, just make a new project, drop a Webbrowser, set URL to http://whatsmyuseragent.com/ and look what it says. In VS2010 it is Mozilla/4.0 (compatible; MSIE 7.0;... so IE 7 – fuchs777 Nov 27 '13 at 16:29
  • Thanks, but the problem is that i have VS 2010 too and i was wondering about the newer version. – Mi-Creativity Nov 27 '13 at 16:51

1 Answers1

0

I've downloaded VS 2013 and "surprisingly" the User Agent was MSIE 7.0 still, nothing changed since the prior versions.. Thanks Microsoft!


UPDATE 2015

I've just downloaded VS 2015 couple days ago and did the same, set the webBrowser URL to whatsmyuseragent.com page and shockingly the User Agent String result was:

Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; .NET4.0C; .NET4.0E)

SO I decided to use this website www.whatismybrowser.com instead and I got this:

enter image description here

So it was IE11 but the problem is with the IE7 compatibility view which ruins it everytime, this why the previous website was showing MSIE 7.0 in the userAgent, and I guess the same was true for VS 2010, VS 2012 and VS 2013.


To "force" rendering the webpage in the latest IE -or versions other than the IE7 compatible one- one of the following could be done:

  1. First : if you have a specific webpage/website to display in the embedded webBrowser and you have control over it add this meta tag to the header:

    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    

    Where IE=edge causes the browser control to render the content in the highest available document mode.

  2. Second : for targeting a specific version of the browser, you can use the FEATURE_BROWSER_EMULATION registry key.


For detailed information:

Community
  • 1
  • 1
Mi-Creativity
  • 9,554
  • 10
  • 38
  • 47