Moving current window to another desktop in Windows 11 using shortcut keys
Nov 5
The year is 2021. In Windows 11, how can I move the current focused window to the next windows desktop using shortcut keys only?
I know that I can switch desktops using these combinations:
Win+Ctrl+→: Switch to the next desktop
Win+Ctrl+←: Switch to the previous desktop
Adding the following shortcut keys seem most comfortable to me - and used in Ubuntu:
Win+Ctrl+Shift+→: Move current window to the next desktop
Win+Ctrl+Shift+←: Move current window to the previous desktop
Similar shortcut keys to above would be acceptable... but even better if I can re-map them to my preferred combination.
Is there anything like this out of the box? Or do I need to install some 3rd party tools?
1 answer
Accepted answer · original discussion
Jan 28
Win+Ctrl+Shift+→: Move current window to the next desktop
Win+Ctrl+Shift+←: Move current window to the previous desktop
This ahk script works for me:
^#+Left::
n := VD.getCurrentDesktopNum()
if n = 1
{
Return
}
n -= 1
VD.MoveWindowToDesktopNum("A",n), VD.goToDesktopNum(n)
Return
^#+Right::
n := VD.getCurrentDesktopNum()
if n = % VD.getCount()
{
Return
}
n += 1
VD.MoveWindowToDesktopNum("A",n), VD.goToDesktopNum(n)
Return
You can find more at https://github.com/FuPeiJiang/VD.ahk and https://www.autohotkey.com/
Your perspective belongs here.
3 question comments
Use comments to ask for clarification. Post a solution as an answer.
Nov 22
Mar 14