pmb6tz / windows-desktop-switcher

An AutoHotKey script for Windows that lets a user change virtual desktops by pressing CapsLock + <num>.
MIT License
1.23k stars 230 forks source link

(Move to desktop) script only run if we compile to exe file #81

Open neilfranci opened 2 years ago

neilfranci commented 2 years ago

When I download the whole repo and run with ahk script, everything works except Capslock + (q,w,e,..) not move my current active window to the desired desktop. But when I right-click to desktop_switcher.ahk > compile (to .exe) and run .exe file, everything works perfectly now. I create this issue keep this open or add it in the readme, IDK if anyone has the same situation as me or not but this is work for me.

Edit: I don't know why but change capslock + 1 to !1(alt + 1) run fine without compile script now.

Trollwut commented 1 year ago

I tried to compile and run the exe.

Desktop switching works fine for me. But if I want to move a window, it doesnt move, but at least switched to the destination desktop.

Did you change other things to make moving work?

Running on Win11 2022H2

neilfranci commented 1 year ago

I tried to compile and run the exe.

Desktop switching works fine for me. But if I want to move a window, it doesnt move, but at least switched to the destination desktop.

Did you change other things to make moving work?

Running on Win11 2022H2

I'm using Win10 22H2, I use default script from source, no change. Compile and run the exe. Caps + 1,2 to switch, Caps + Q,W to move active window to destination desktop.

Trollwut commented 1 year ago

Ahhh there's the thing: Moving is generally a broken thing on Win11 :)

everzwijn commented 1 year ago

I can confirm that moving apps between desktops is broken on Windows 11 22H2 (as opposed to Windows 11 21H2 where the 'old' virtualdesktopaccessor.dll works). A new virtualdesktopaccessor.dll is needed for 22H2.

hrdkmishra commented 1 year ago

https://github.com/FuPeiJiang/VD.ahk this project is working completely fine might have a look at it

vdegenne commented 1 year ago

@hrdkmishra thanks for the discovery!