8

How do i set task bar buttons to "never combine" using the registry?

3 Answers 3

9

You're looking for the "never group taskbar buttons" feature.

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel = 00000002

See KnifeySpoony's comment on an article about Windows 7 taskbar buttons at HowToGeek for more information.

TaskbarGlomLevel – Changes the grouping so that the windows do not turn into squares and overlap each other. They will still group if you have too many windows open. If you want to never group windows, change this value to 00000002.

2
  • Could you post this in .reg file form? Thanks! Feb 17, 2017 at 16:29
  • 1
    @Aaron Franke Paste the contents of pastiebin.com/58b988beb8aea into a REG file. That should also set the option for all monitors on Windows 10. Mar 3, 2017 at 15:17
3

Standing on the shoulders of Rob:

Via powershell (src):

#http://superuser.com/questions/135015
$taskbarButtonsRegKey = 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced'
if (((Get-ItemProperty -path $taskbarButtonsRegKey ).TaskbarGlomLevel ) -Ne 2)
{
    Set-ItemProperty -Path $taskbarButtonsRegKey -Name "TaskbarGlomLevel" -Value 00000002
}

Via chocolatey (package):

choco install taskbar-never-combine
1
0

Rather old question, but here is my 2 cents in VBScript to programmatically change the setting in registry then refresh the Taskbar to take the change into account without rebooting or killing explorer.exe.

Solution 1 : Requires having Excel installed to make the call to the Win32 API via VBA in order to refresh the Taskbar. A bit heavy solution, since it requires loading the entire application in background.

Dim WshShell, nKey
Set WshShell = WScript.CreateObject("WScript.Shell")

nKey= WshShell.RegRead("HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel")

If nKey = 0 Then
    WshShell.RegWrite "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel", 2, "REG_DWORD"
ElseIf nKey = 2 Then
    WshShell.RegWrite "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel", 0, "REG_DWORD"
End If

'Private Const WM_WININICHANGE = &H1A&
'Private Const WM_SETTINGCHANGE = WM_WININICHANGE
'~~> DOES NOT WORK
'litterals seem required even if documentation should allow defining a constant with another constant
'https://www.vbsedit.com/html/61ad308e-6c17-4cd5-a9a6-8a47dc628ba1.asp
'https://stackoverflow.com/questions/15513606/understanding-const-expression-in-vbscript
'Script56.chm

Private Const WM_SETTINGCHANGE = &H1A&
Private Const HWND_BROADCAST = &HFFFF&

'http://www.cpearson.com/excel/call.htm

Dim excel
Set excel = CreateObject("Excel.Application")

Dim strMacro
strMacro = "CALL(""user32"",""SendMessageA"",""JJJJC""," & HWND_BROADCAST & "," & WM_SETTINGCHANGE & "," & 0 & ",""TraySettings"")"
excel.ExecuteExcel4Macro(strMacro)

Solution 2 : More complicated, but usually quicker, using PowerShell to run an inline script making the call.

Dim WshShell, nKey
Set WshShell = WScript.CreateObject("WScript.Shell")

nKey= WshShell.RegRead("HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel")

If nKey = 0 Then
    WshShell.RegWrite "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel", 2, "REG_DWORD"
ElseIf nKey = 2 Then
    WshShell.RegWrite "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TaskbarGlomLevel", 0, "REG_DWORD"
End If

command = "powershell.exe -nologo -command ""add-type -name user32 -namespace '' -memberDefinition '[DllImport(\""user32.dll\"", CharSet=CharSet.Auto)] public static extern IntPtr SendMessageTimeout(IntPtr hWnd, uint Msg, UIntPtr wParam, string lParam, uint fuFlags, uint uTimeout, out UIntPtr lpdwResult);'; $HWND_BROADCAST = [intptr]0xffff; $WM_SETTINGCHANGE = 0x1a; $result = [uintptr]::zero; [user32]::SendMessageTimeout($HWND_BROADCAST, $WM_SETTINGCHANGE, [uintptr]::Zero, \""TraySettings\"", 2, 5000, [ref]$result); """

Set objShell = CreateObject("Wscript.shell")
objShell.run command,0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.