Link to home
Start Free TrialLog in
Avatar of Luis Diaz
Luis DiazFlag for Colombia

asked on

Identify default shortcuts

Hello experts,
I would like to know to check which are the various windows shortcut set up in my computer.
Can I do it with a powershell or a windows batch command?
Thank you in advance for your help.
Avatar of ZeropointNRG
ZeropointNRG
Flag of Australia image

What do you mean exactly? Setup for your specific keyboard? Did you customize them?

Or do you want a list of various shortcut commands for windows? If so, here's a list.

https://www.groovypost.com/howto/windows-10-keyboard-shortcuts

If not, you need to be more specific in what shortcuts you are asking to see.
Avatar of Luis Diaz

ASKER

I mean, what I have in my computer.
Example: I have create a shortcut keyboard to open a specific folder. I need to identify this shortcut.
You mean you made a macro on your keyboard to perform the action of opening a folder? Or are you talking about shortcut icons? Walk me through the process you used to create this shortcut.
Okay I think you're talking about the default windows keyboard shortcuts? In this case, you are unable to change these. But you can disable them. But before you do that, want to tell us what you want to do? Do you want to remap your keyboard?
Yes, I want to remap my shortcuts.
For example I have: win + alt + n that open onenote note I want to deactivate this shortcut to use win + alt + n for another action.
Same as win + ctrl + n that open default application as narrator. I want to deactivate this shortcut to use win + ctrl + n for another action.
Thank you in advance for your help.
ASKER CERTIFIED SOLUTION
Avatar of ZeropointNRG
ZeropointNRG
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thank you unable to do the action right now. Ahk file should be always active in my PC or one I launched I can remove it?
It has to be installed forever. If you don't want it installed, then you have to create an exe of the ahk file using the ahk-exe maker (also comes installed with ahk.) This will install the ahk resources into the exe itself so you can uninstall ahk.

It takes no resources though, seriously, you won't notice anything.
Noted. If I want to add a new remapping line I added in the same file or the best is to keep individual files by remapping action? Same process for new customized shortcuts.
I forgot to point out, you don't need to remap win+alt+n or win+ctrl+n you can simple use any combination as the hotkey;

Example:

#n::
send {LWin down}{r}{LWin up}
return

Open in new window

This opens the run box with the combination of "Windows key + n."

But if you want to use your combination then your script for those keys would look like this;;

#!n::
send "your key combination goes here."
return

Open in new window


"#" denotes the windows key,
 "!" denotes the Alt key
"n" denotes the letter N.
You can add them to the same file like this;

F1::
Send {F2}
return

F2::
Send {F3}
return

Open in new window

etc, etc Here when you press F1, it will act as the F2 key, and F2 acts as F3 key. You can get creative.

You can do all sorts of things like only allowing the hotkeys to be usable when a certain window is active;

#IfWinActive, ahk_class Notepad
F1::
Send {F2}
return

Open in new window


The F1 key will only act as the F2 key only when notepad is the active window.. Outside of it, it will act as the normal F1 key.
Ok, noted and in that case it will overwrite the default shortcut key?
E.g: if I create an autohotkey to open notepad ++ with the keys: win+ctrl+n what happen with current shortcut key: win+ctrl+n that open narrator?
The original key combination is remapped to whatever you make it.

#^n::
Run C:\Program Files\Notepad++\notepad++.exe
return

Open in new window

Will open notepad++ (x64) using the Windows+ctrl+n combination.

If you want to open the narrator, you have to make a new combination for it using the methods above or close the script to get the original function of that combination back.
Thank you very much for your help.

I installed as recommended and created my shortcuts.


;====================================
;Special characters
;====================================

#If GetKeyState("CapsLock", "T")=1
!e::Send {ASC 144}
!i::Send {ASC 214}
!n::Send {Asc 165}
!o::Send {ASC 224}
!u::Send {Asc 233}
!a::Send {ASC 181}

#If GetKeyState("CapsLock", "T")=0
!a::Send {ASC 160}
!e::Send {ASC 130}
!i::Send {ASC 161}
!o::Send {ASC 162}
!u::Send {Asc 163}
!n::Send {Asc 164}
!+?::Send {ASC 168}
!+!::Send {ASC 173}

; End if
#If

;====================================
;Run Cmd
;====================================

#!c::Run C:\Windows\System32\cmd.exe

;====================================
;Run Powershell
;====================================

#^p::Run C:\Windows\SysWOW64\WindowsPowerShell\v1.0\powershell_ise.exe

;====================================
;Run Chrome
;====================================

#!h::Run C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
  
;====================================
;Run Notepad ++
;====================================

#!n::Run C:\Program Files\Notepad++\notepad++.exe

Open in new window


Last questions:

1-return line is recommended or not?
2-How to run .ahk file everytime when I start my computer

Thank you very much for your help and support.
Never mind the second question, I was able to find my answer here:
https://www.autohotkey.com/docs/FAQ.htm
I went to start up folder by launching:
 shell:common startup 

Open in new window

And place my .ahk file.
Nicely done :)

No, you don't need to return each command, I just make it a habit to make sure nothing get's stuck.
Thank you very much for your help.
My Pleasure!