[SOLVED] Keyboard shortcuts dont work

ch33r

Distinguished
BANNED
Jun 13, 2010
316
4
18,685
I made a keyboard shortcut to open an application, and it doesn't work. Like... It literally just doesnt work. Ive researched forums. Simple googling... blah blah blah. It doesn't matter what folder I put it in, it literally just doesn't work. Is the feature literally broken or what the hell?
 
Solution
AutoHotKey is a scripting language. It's not a program with an interface, it's an interpreter. That means it needs a script to run. You create a script in Notepad or any plain text editor, save it as an .AHK file, and then you can run it.

An example script that can be created in Notepad:

; The next line means Ctrl+Alt+A. This line is a comment.
^!A::
Run "wordpad.exe"

Copy/paste the 3 lines into Notepad. Save it as WordPadShortCut.ahk and then you can double click on it to run it. While it's running, you'll see it in the tray and can close it out by right clicking on it and choosing Exit. While it's running, pressing Ctrl+Alt+A will open Wordpad.

If you like the script, you can then right click...

gardenman

Splendid
Moderator
What key combination did you use and have you tried others? I set one up the other day and noticed that it didn't work when I had some applications open. Or, I had to change focus to the desktop before it would work.

An alternative is AutoHotKey. It's a pretty easy to use scripting language (I can help create a script if needed) and once you create a script, you can convert it to an .EXE and it runs as a tray icon. I'm pretty sure the shortcuts created in it will override most default Windows key combinations also.
 

ch33r

Distinguished
BANNED
Jun 13, 2010
316
4
18,685
What key combination did you use and have you tried others? I set one up the other day and noticed that it didn't work when I had some applications open. Or, I had to change focus to the desktop before it would work.

An alternative is AutoHotKey. It's a pretty easy to use scripting language (I can help create a script if needed) and once you create a script, you can convert it to an .EXE and it runs as a tray icon. I'm pretty sure the shortcuts created in it will override most default Windows key combinations also.
I don't know the language to code in autohotkey. Why is there no gui?
 

gardenman

Splendid
Moderator
AutoHotKey is a scripting language. It's not a program with an interface, it's an interpreter. That means it needs a script to run. You create a script in Notepad or any plain text editor, save it as an .AHK file, and then you can run it.

An example script that can be created in Notepad:

; The next line means Ctrl+Alt+A. This line is a comment.
^!A::
Run "wordpad.exe"

Copy/paste the 3 lines into Notepad. Save it as WordPadShortCut.ahk and then you can double click on it to run it. While it's running, you'll see it in the tray and can close it out by right clicking on it and choosing Exit. While it's running, pressing Ctrl+Alt+A will open Wordpad.

If you like the script, you can then right click on the WordPadShortCut.ahk file and choose "Compile Script". Give it a few seconds and it will create an executable file for you, WordPadShortCut.exe. At that point, AutoHotKey is no longer needed and can be removed from your PC. Just keep the WordPadShortCut.exe if you want.

For more info about shorcut keys, see this:
https://forums.tomshardware.com/threads/removal-of-win10-keyboard-shortcuts.3275503/#post-20074245

If you have more questions let me know. You didn't give me the exact key combination that you're going to use, or what program you'll run. You will need to use the full path and filename to the program if it's in Program Files.
 
Solution