I have 2 ahk files, lets call them "file-a" and "file-b".
File-a has bunch of capslock + key hotkeys.
File-b has capslock+u, capslock+t and capslock+shift+t hotkeys.
If I load file-b after file-a, file-b hotkeys work, but if i do reverse they don't.
Is there a way to make file-b capslock hotkeys work, even if its loaded before file-a? I would prefer not to combine both files, as file-b is quite big.
EDIT: This only happens if I put "SetCapslockState, AlwaysOff" on both files.
conflict between 2 files that use capslock modifiers
Re: conflict between 2 files that use capslock modifiers
Both processes install a keyboard hook, which (in order to make the hotkeys/SetCapslockState work properly) disrupts the native function and the hotkeys of the other process. The process which loads the hook last will the processed first, as you have noticed. You can have a script drop and reload the hook by having it call Suspend,On and then Suspend,Of. Hooks by elevated processed are processed with higher priority too, for example if you run the script as administrator.
You don't want to combine the scripts, but would an #Include not work? Having a script require the highest priority hook sounds annoying.
You don't want to combine the scripts, but would an #Include not work? Having a script require the highest priority hook sounds annoying.
Re: conflict between 2 files that use capslock modifiers
I tried adding #Include [script-b-path] in script-a. It simply turns off script-a hotkeys, while turning on script-b ones....
Who is online
Users browsing this forum: Xtra and 119 guests