Solution – Failed To Launch IE Driver Using Selenium WebDriver

Solution – Failed To Launch IE Driver Using Selenium WebDriver

Failed To Launch IE Driver Using Selenium WebDriver?

I heard from many Selenium WebDriver users that they failed to launch IE driver using Selenium WebDriver. Here are the solutions for the common issues most of us might have faced.

Earlier, we have seen “ How to Run Selenium WebDriver Script in Internet Explorer browser “. Perhaps, we may failed to launch IE driver using Selenium WebDriver. Error might be similar to the one which we placed in the below screenshot.

Error 1: Exception in thread “main” org.openqa.selenium.remote.SessionNotFoundException: Unexpected error launching Internet Explorer. Protected Mode settings are not the same for all zones. Enable Protected Mode must be set to the same value (enabled or disabled) for all zones. (WARNING: The server did not provide any stacktrace information).

Solution: To fix this error, we need to enable protected mode for all zones.

Follow the below steps to enable protected mode for all zones.

  1. Open Internet Explorer
  2. Go to Tools menu – Internet Options
  3. Select Security Tab
  4. In Select a zone to view or change security settings choose Internet and select the check box of Enable protected mode (requires restarting Internet Explorer).
  5. Similarly, select the check box of Enable protected mode (requires restarting Internet Explorer) for other three such as Local Intranet, Trusted sites, and Restricted sites.

Error 2 : Exception in thread “main” org.openqa.selenium.remote.SessionNotFoundException: Unexpected error launching Internet Explorer. Browser zoom level was set to 200%. It should be set to 100% (WARNING: The server did not provide any stacktrace information).

Solution: To fix this error, we need to set Zoom level of Internet Explorer browser to 100%

Follow the below steps to set Zoom level to 100%

  1. Open Internet Explorer
  2. To to ViewZoomSelect 100%

Do you want to try running the Selenium WebDriver script in Google Chrome. To run the quick start click on the below link.

How to Run Selenium WebDriver Script in Chrome browser