Selenium – Disable Internet Explorer 11 First Run Wizard

internet explorerselenium

I have a Selenium UI couple of tests running on a Windows Server 2012 scheduled task.
But I have them failing again and again in the scheduled task (not in my development server) and Internet Explorer; which I believe it is due to the first run wizard pop-up, the one that asks you about using "Recommended security, privacy and compatibility settings or not).
I have asked the system administrator that has the scheduled task to get rid of that pop-up in his Internet Explorer, but with no luck. I have also ask him to disable it with this msdn blog solution

http://blogs.msdn.com/b/akshayns/archive/2009/08/19/how-to-disable-internet-explorer-8-welcome-screen-for-all-users.aspx

But it seems out-to-date. Any ideas or how can I disable that pop-up in the group policy, or in the windows server or using selenium ui in the code?

Many thanks in advance

Best Answer

you have 2 ways:

by group policy editor or by editing the windows registry:

Method #1: Using Group Policy Editor

Using Group Policy Editor is probably the best method, because it can be used either locally, on one computer, or in an Active Directory environment by utilizing the GPO power.

  1. Press Start button + R (the Run command), type gpedit.msc and press Enter to launch the Group Policy Editor. Note: In an Active Directory environment, open gpmc.msc and either edit an existing GPO, or create a new one and link it to the domain level, or to an OU of your choice.

  2. In the left pane, expand User Configuration > Administrative Templates > Windows Components > Internet Explorer.

  3. On the right pane, double-click on “Prevent running First Run wizard". A new settings window will open up.

  4. Set the value to “Enabled”.

    1. In the options section you must choose one of the two options from the drop-down menu:

•Go directly to “Welcome To IE” page •Go directly to home page

You need to choose one of the two, otherwise the configuration will not work. The first option configures IE to skip the Welcome screen and go directly to your home page, whatever it is.

The second option configures IE to skip the Welcome screen and and go to the “Welcome to Internet Explorer” page directly.

  1. Click Apply to save the settings then click OK and close the Group Policy Editor window.

  2. Press Start button + R (the Run command) and type gpupdate /force and press Enter to refresh the Group Policy on the computer.

Method #2: Using Registry Editor

You can use this method to either manually configure one computer, or generate a .REG file to import it on other machines. Warning:

This document contains instructions for editing the registry. If you make any error while editing the registry, you can potentially cause Windows to fail or be unable to boot, requiring you to reinstall Windows. Edit the registry at your own risk. Always back up the registry before making any changes. If you do not feel comfortable editing the registry, do not attempt these instructions. Instead, seek the help of a trained computer specialist.

  1. Press Start button + R to open run command dialog box. Type regedit and press Enter to open the Registry Editor. You may be prompted with a UAC prompt, click "Yes".

  2. Navigate to the following path: HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Internet Explorer\Main Note: The above branch does not exist by default, and has to be created manually, or by running the .REG file available at the end of this article.

  3. Right click on the right pane and select New > DWORD (32-bit) Value.

  4. Enter DisableFirstRunCustomize.

  5. Right-click on the new entry it and choose “Modify”.

    1. Modify its DWORD (32-bit) Value to “1” (without the quotes) and click OK.
  6. Exit the Registry Editor.

Note: You can use this .REG file to import the same setting to your computer: Windows Registry Editor Version 5.00

;Disable IE11 Welcome Screen

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Internet Explorer\Main]

"DisableFirstRunCustomize"=dword:00000001

Copy the above text into a new text file, and save it as "DisableIEWelcome.reg".

Taken from here : https://mkcheah88.blogspot.co.il/2014/06/microsoft-how-to-disable-internet.html