I have a problem in selenium uploading files in IE11. In my c# code I make
driver.FindElement(By.Id("file")).SendKeys(filepath);
and in 95% of executions it works OK in IE11 but at others I see only opened upload window and test hangs after it.
I'm sure that path to image is correct, I see it in console of selenium server.
Does anybody have some ideas of reason of such behavior?
UPDATE 08/10/2015:
I updated selenium server from 2.45 version to 2.47.1 and it seems that issue appears not so often as before but it is still there
I verified confuration on IE
The IEDriverServer exectuable must be downloaded and placed in your PATH.
On IE 7 or higher on Windows Vista or Windows 7, you must set the Protected Mode settings for each zone to be the same value. The value can be on or off, as long as it is the same for every zone. To set the Protected Mode settings, choose "Internet Options..." from the Tools menu, and click on the Security tab. For each zone, there will be a check box at the bottom of the tab labeled "Enable Protected Mode".
Additionally, "Enhanced Protected Mode" must be disabled for IE 10 and higher. This option is found in the Advanced tab of the Internet Options dialog.
The browser zoom level must be set to 100% so that the native mouse events can be set to the correct coordinates.
For IE 11 only, you will need to set a registry entry on the target computer so that the driver can maintain a connection to the instance of Internet Explorer it creates. For 32-bit Windows installations, the key you must examine in the registry editor is HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. For 64-bit Windows installations, the key is HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. Please note that the FEATURE_BFCACHE subkey may or may not be present, and should be created if it is not present. Important: Inside this key, create a DWORD value named iexplore.exe with the value of 0.
My configuration is correct
Related
I have to test a product on Internet Explorer but when I try to start it always Edge browser is opened. I tried to set IE as default browser but did not help. I try to set Chrome or Firefox as default but also not help. I tried to uninstall then reinstall IE component from 'Uninstall programs - Turns windows feature on or off' but also did not help.
I have upgraded my Windows to Version 1909 x64 but also before this update the problem existed. I am using a Dell Latitude E5470 laptop. I also search the IE and Edge group policy settings but I don't find anything which help solving this problem.
Your suggestions, ideas and help would be very appreciated.
Thanks.
For me, I was able to fix the behavior by searching for "Internet Explorer Compatibility" in the Edge settings panel. Then setting the "Open Sites in Edge" setting to "Never."
I have had a similar behavior in Windows 10 20H2 (As of writing this answer, the latest Windows 10 build so far). I had a scheduled task which opens a website at a given time, the command there is:
"C:\Program Files\Internet Explorer\iexplore.exe" https://some.webiste.com
After upgrading to 20H2 it always opened in Edge, also manually browsing to that website was redirected to Edge.
I found a setting in Internet Explorer under Internet Options -> Advanced Tab -> Browsing section -> Uncheck Enable third party extensions.
Note: This might need a restart to take effect and disable also other extensions but unfortunately as of this day there seems to be no other options to browse a website in IE which needs IE for one or the other reason.
Edit:
This behavior I was experiencing seems to be a DLL (ie_to_edge_bho.dll) file which comes with Edge and is being installed in IE. There is a static list of websites which get automatically redirected to Edge. Disabling this extension is greyed out and not supported out of the box, other than disabling all extensions via the option described above.
This setting lets you decide whether to open all sites not included in the Enterprise Mode Site List in Microsoft Edge. If you use this setting, you must also turn on the Administrative Templates\Windows Components\Internet Explorer\Use the Enterprise Mode IE website list policy setting and you must include at least one site in the Enterprise Mode Site List.
Enabling this setting automatically opens all sites not included in the Enterprise Mode Site List in Microsoft Edge.
Disabling, or not configuring this setting, opens all sites based on the currently active browser.
Note: If you've also enabled the Administrative Templates\Windows Components\Microsoft Edge\Send all intranet sites to Internet Explorer 11 policy setting, then all intranet sites will continue to open in Internet Explorer 11.
https://admx.help/?Category=Windows_10_2016&Policy=Microsoft.Policies.InternetExplorer::RestrictInternetExplorer
The problem was with 20H2(Microsoft Windows 10 Enterprise ver 10.0.19042) when I received the same complaint from multiple users.
So this has been sorted out using below registry fix as mentioned by #alpar
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Internet Explorer\Main\EnterpriseMode and set RestrictIE value from 1 to 0
For me, the correct answer was the one provided by #josibu.
I was trying to use the performance profiler in Visual Studio 2019 for a Web project. For this function, there is no way to convince Visual Studio 2019 to use anything other than Internet Explorer. Even on Windows 11, it tries to run iexplore.exe when no such program exists. For those machines that do have Internet Explorer installed, but crippled by Microsoft, disable third party extension, as directed by #josibu.
You may get a message that the setting will not take effect until you restart your system. In my case, this was not needed. The change worked after I simply closed Internet Explorer.
I was trying to test one of my application on Microsoft edge browser in VM and due to some updates my Edge browser has been updated to Chromium version (latest version) and i was unable to downgrade it or unable to find any older version .
I have also tried following MSDN post for using both legacy and new version of Edge side by side by even though i follow those steps i was unable to see the old Edge legacy versions.
https://learn.microsoft.com/en-us/deployedge/microsoft-edge-sysupdate-access-old-edge
Can some one suggest if there is any other work around to make this happen
From the article, the Allow Microsoft Edge Side by Side browser experience should be enabled before the new version of Microsoft Edge is deployed to your users' devices.
So, I suggest you could try to uninstall the New Microsoft Edge from the Control Panel first, then, according the above article to enable the Allow Microsoft Edge Side by Side browser experience Group Policy. After that, please refer to the following steps the check the Registry and make sure the Allowsxs value is 1.
Press WIN+R keys together to open RUN dialog box. Now type regedit in RUN dialog box and press Enter. It'll open Registry Editor.
Go to following key: HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft
Find the EdgeUpdate Key (if not find this key, create a new key under Microsoft key and set its name as EdgeUpdate)
Select EdgeUpdate key and in right-side pane, right-click on empty area and select New -> DWORD (32-bit) Value option. Set the new DWORD name as Allowsxs and set its value to 1.
Then, reinstall the New Microsoft Edge, you can open and use both Microsoft Edge web browsers.
Besides, some new updates can cause the Microsoft Edge Legacy shortcut in Start Menu not working or hide, if that is the case, please refer to the following steps to create a new shortcut to Legacy Microsoft Edge browser:
Press WIN+R keys together to launch RUN dialog box.
Now type shell:appsfolder in RUN dialog box and press Enter key.
It'll open Applications folder in File Explorer. Look for old Microsoft Edge application having old White icon.
Double-click on it and it'll launch old Microsoft Edge without any issue.
Now you can right-click on the application and select Pin to Start, Pin to Taskbar or Create Shortcut option to add its shortcut to Start Menu, Taskbar or Desktop.
It seems we can't enable the legacy version in windows server VM.
Please follow the below discussion on this.
Thanks.
https://techcommunity.microsoft.com/t5/discussions/tutorial-how-to-run-legacy-and-chromium-based-edge/m-p/1200283#M25430
So I have this issue, I have a web application that needs to open a popup in IE that is 64bit.
By default, it launches in 32bit. So I changed the 2 IE settings:
Trusted Sites -> Enable Protected Mode
Advanced Security -> Enable 64 bit processes for Enhanced Protected Mode
When I navigate to my site, if i use IP address, or short hostname, it behaves as expected and launches in 64 bit. But if I launch my site with the FQDN xxxxx.domain.com it still launches in 32 bit. Any ideas?
What is your IE version and OS version? Is the manager process of IE 64 bit?
You could try the following methods:
Enable UAC
If UAC is off, Enhanced Protected Mode doesn't do anything. You could enable UAC by editing the registry: Set EnableLUA value to 1 in the following path:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System
Or open the Control Panel, select User Accounts, click Change User Account Control settings, move the slider up, then click OK.
Disable LCIE
By disabling LCIE, there will be only one process no matter how many tabs running in IE. If the main process is 64 bit, then you'll get a single 64 bit process for all the tabs. Save below code as a reg file, then double click it to make it work in registry:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Internet Explorer\Main]
"TabProcGrowth"="0"
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main]
"TabProcGrowth"="0"
[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\Main]
"TabProcGrowth"="0"
I'm having issues that IE version 11 stuck randomly on some page. the code is working fine because whenever i restart the program sometimes it work but the most annoying will be randomly stuck after click and load the page. is this normal on IE? i never had this type of issues when using Chrome. but this website works only at IE. can i know the cause of this problem is it the driver?, the website itself? or Network security?
While you work with Internet Explorer v11 you need to configure your test framework with the Required Configuration. Apart from these specifically only for IE 11 you will need to set a registry entry on the target computer so that the driver can maintain a connection to the instance of Internet Explorer it creates as follows:
For 32-bit Windows installations, the key you must examine in the registry editor is:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE.
For 64-bit Windows installations, the key is:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE.
Trivia
How does the registry entry HKEY_LOCAL_MACHINE\…\FEATURE_BFCACHE for InternetExplorerDriver solves the Internet Explorer 11 issue?
Internet Explorer Protective mode setting and Zoom levels
Selenium InternetExplorerDriver doesn't get focus on the window
How to ignore protected Mode Settings for Internet Explorer using setCapability() through Selenium and Java?
I've come upon a strange issue while setting up a Selenium Grid. My RemoteWebDriver works once, and then throws a NoSuchWindowException if I try to do anything else with it.
For example, if I run the following test (which I wrote just to explore this problem):
#Test
public void testStuff() {
try{Thread.sleep(2000);}catch(Exception e){}
driver.get("http://www.google.com");
try{Thread.sleep(2000);}catch(Exception e){}
driver.get("http://www.stackoverflow.com");
System.out.println(driver.getTitle());
}
An IE browser pops up on the virtual machine that I'm sending it to. That browser then successfully goes to google. However, when I try to do anything else with it (like go to another website, or get the window's title), I get the following exception:
org.openqa.selenium.NoSuchWindowException: Unable to get browser(WARNING: The server did not provide any stacktrace information)
I have tried all sorts of combinations, with the same result every time: I can successfully call a method off of the RemoteWebDriver once, but the second time it throws this exception.
Does anyone have any ideas what might be causing it?
Things I've checked:
The IEDriverServer and the VM are both 64-bit.
The console for both the Hub and the Node yield no useful clues. The Node console contains:
INFO - Executing: [get: http://www.google.com] at URL: /session/de0a7b62-33a1-4330-b9a9-25b99f5504-cf/url)
INFO - Done: /session/de0a7b62-33a1-4330-b9a9-25b99f5504-cf/url
INFO - Executing: [get: http://www.stackoverflow.com] at URL: /session/de0a7b62-33a1-4330-b9a9-25b99f5504-cf/url)
INFO - Done: /session/de0a7b62-33a1-4330-b9a9-25b99f5504-cf/url
WARN - Exception thrown
org.openqa.selenium.NoSuchWindowException: Unable to get browser (WARNING: The server did not provide any stacktrace information)
In response to Richard's comment, the WebDriver really is quitting at then end of the test. I'm printing out the following in the console:
successfully strt RemoteWebDriver: internet explorer on WINDOWS (40b01604-9217-4f67-b809-61cd90d23c84)
preparing to quit RemoteWebDriver: internet explorer on WINDOWS (40b01604-9217-4f67-b809-61cd90d23c84)
successfully quit RemoteWebDriver: internet explorer on WINDOWS (null)
Also, in the Task Manager on the VM, the "IEDriverServer" process goes away at the end of the test. But the weird thing is, The browser itself does not close. I have no idea what could be causing that, and whether or not it is related.
That sounds to me as beeing a typical problem with the IEDriverServer.exe, occurring if configuration on a node machine isn't done properly.
Be shure to follow all requirements described on Selenium Website. Corresponding part cited here:
Required Configuration
The IEDriverServer exectuable must be downloaded and placed in your PATH.
On IE 7 or higher on Windows Vista or Windows 7, you must set the Protected Mode settings for each zone to be the same value. The value can be on or off, as long as it is the same for every zone. To set the Protected Mode settings, choose "Internet Options..." from the Tools menu, and click on the Security tab. For each zone, there will be a check box at the bottom of the tab labeled "Enable Protected Mode".
Additionally, "Enhanced Protected Mode" must be disabled for IE 10 and higher. This option is found in the Advanced tab of the Internet Options dialog.
The browser zoom level must be set to 100% so that the native mouse events can be set to the correct coordinates.
For IE 11 only, you will need to set a registry entry on the target computer so that the driver can maintain a connection to the instance of Internet Explorer it creates. For 32-bit Windows installations, the key you must examine in the registry editor is HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. For 64-bit Windows installations, the key is HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. Please note that the FEATURE_BFCACHE subkey may or may not be present, and should be created if it is not present. Important: Inside this key, create a DWORD value named iexplore.exe with the value of 0.
I had the same issue and was able to solve it with these hints.