07-28-2015, 10:38 AM
Alright, it's possible to use just any key, but some keys require the use of scan codes.
If a key doesn't work for you, proceed like this:
Add #InstallKeybdHook as the second line in the PuthToTalk.ahk script.
Start AHK
Press the key that you want to use (a few times if you want to be sure)
In the try bar icon, select "Open"
In the window that opened, select View->Key History and Script info
Press f5
Find the key. There will be some line that lists the key under the "Key" column
Note the second value in that line (under the SC header). This is the scan code
In the script, you can use scan codes instead of keys with a 'SC' prefix. So, for example, the '^' key on the german keyboard (top row before the number keys) has a scan code of 029, so the script would look something like this (if you want CTRL+that key)
If a key doesn't work for you, proceed like this:
Add #InstallKeybdHook as the second line in the PuthToTalk.ahk script.
Start AHK
Press the key that you want to use (a few times if you want to be sure)
In the try bar icon, select "Open"
In the window that opened, select View->Key History and Script info
Press f5
Find the key. There will be some line that lists the key under the "Key" column
Note the second value in that line (under the SC header). This is the scan code
In the script, you can use scan codes instead of keys with a 'SC' prefix. So, for example, the '^' key on the german keyboard (top row before the number keys) has a scan code of 029, so the script would look something like this (if you want CTRL+that key)
Code:
~^SC029:: ;Change this for the button you want to use
  VA_SetMasterMute(false, "capture")
  KeyWait,SC029
  VA_SetMasterMute(true, "capture")
  Return