Skip to main content
edited body
Source Link

The answer from Judy Li still worked for me on 2021-01-04 with the latest windows 10 built. However, I had to update the the number of tab's and sleep commands.

The updated steps are:

  1. Create a VBS files with the code below
  2. Open folder shell:startup with [win]+[r] or file explorer
  3. Store the file in the startup folder to execute the script with each restart

VBS Code

Set WshShell = WScript.CreateObject("WScript.Shell")

' Open the default settings window
WshShell.Run "%windir%\system32\control.exe /name Microsoft.DefaultPrograms /page pageDefaultProgram\pageAdvancedSettings?pszAppName=google%20chrome"
WScript.Sleep 5000 ' Wait until open (adjust if necessary)

' Adjust number of tabs until you reach the browser choice setting
WshShell.SendKeys "{TAB}" 
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"

' Open the browser choice menu
WshShell.SendKeys " " 
WScript.Sleep 500 ' Wait until open

WshShell.SendKeys "{TAB}" ' Move down one selection
WshShell.SendKeys " " ' Set current selectinoselection as default browser

WScript.Sleep 500 ' Wait until open
' Uncomment the line below to outomatically close the settings window
' WshShell.SendKeys "%{F4}" 
WScript.Quit

The answer from Judy Li still worked for me on 2021-01-04 with the latest windows 10 built. However, I had to update the the number of tab's and sleep commands.

The updated steps are:

  1. Create a VBS files with the code below
  2. Open folder shell:startup with [win]+[r] or file explorer
  3. Store the file in the startup folder to execute the script with each restart

VBS Code

Set WshShell = WScript.CreateObject("WScript.Shell")

' Open the default settings window
WshShell.Run "%windir%\system32\control.exe /name Microsoft.DefaultPrograms /page pageDefaultProgram\pageAdvancedSettings?pszAppName=google%20chrome"
WScript.Sleep 5000 ' Wait until open (adjust if necessary)

' Adjust number of tabs until you reach the browser choice setting
WshShell.SendKeys "{TAB}" 
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"

' Open the browser choice menu
WshShell.SendKeys " " 
WScript.Sleep 500 ' Wait until open

WshShell.SendKeys "{TAB}" ' Move down one selection
WshShell.SendKeys " " ' Set current selectino as default browser

WScript.Sleep 500 ' Wait until open
' Uncomment the line below to outomatically close the settings window
' WshShell.SendKeys "%{F4}" 
WScript.Quit

The answer from Judy Li still worked for me on 2021-01-04 with the latest windows 10 built. However, I had to update the the number of tab's and sleep commands.

The updated steps are:

  1. Create a VBS files with the code below
  2. Open folder shell:startup with [win]+[r] or file explorer
  3. Store the file in the startup folder to execute the script with each restart

VBS Code

Set WshShell = WScript.CreateObject("WScript.Shell")

' Open the default settings window
WshShell.Run "%windir%\system32\control.exe /name Microsoft.DefaultPrograms /page pageDefaultProgram\pageAdvancedSettings?pszAppName=google%20chrome"
WScript.Sleep 5000 ' Wait until open (adjust if necessary)

' Adjust number of tabs until you reach the browser choice setting
WshShell.SendKeys "{TAB}" 
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"

' Open the browser choice menu
WshShell.SendKeys " " 
WScript.Sleep 500 ' Wait until open

WshShell.SendKeys "{TAB}" ' Move down one selection
WshShell.SendKeys " " ' Set current selection as default browser

WScript.Sleep 500 ' Wait until open
' Uncomment the line below to outomatically close the settings window
' WshShell.SendKeys "%{F4}" 
WScript.Quit
Source Link

The answer from Judy Li still worked for me on 2021-01-04 with the latest windows 10 built. However, I had to update the the number of tab's and sleep commands.

The updated steps are:

  1. Create a VBS files with the code below
  2. Open folder shell:startup with [win]+[r] or file explorer
  3. Store the file in the startup folder to execute the script with each restart

VBS Code

Set WshShell = WScript.CreateObject("WScript.Shell")

' Open the default settings window
WshShell.Run "%windir%\system32\control.exe /name Microsoft.DefaultPrograms /page pageDefaultProgram\pageAdvancedSettings?pszAppName=google%20chrome"
WScript.Sleep 5000 ' Wait until open (adjust if necessary)

' Adjust number of tabs until you reach the browser choice setting
WshShell.SendKeys "{TAB}" 
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"

' Open the browser choice menu
WshShell.SendKeys " " 
WScript.Sleep 500 ' Wait until open

WshShell.SendKeys "{TAB}" ' Move down one selection
WshShell.SendKeys " " ' Set current selectino as default browser

WScript.Sleep 500 ' Wait until open
' Uncomment the line below to outomatically close the settings window
' WshShell.SendKeys "%{F4}" 
WScript.Quit