Best way to map shortcut keys in Windows 7?


Recommended Posts

My old media friendly keyboard at work died. IT guy only had standard Dell ones lying around. I'm missing my play/pause button and volume up and down buttons. 

 

Is there a way to map my function keys to do these tasks? 

 

I'm using Windows 7 and itunes. 

 

Thanks.

Link to comment
Share on other sites

Was in a similar situation a few months back, went from a Logitech keyboard with a gazillion keys to one that's the "traditional" layout (and 1000% more durable). AutoHotKey can do that rather easily.

Just a simple example, easily change it to whatever keystrokes you want:

^!m::
Send {Volume_Mute}
return

^!up::
Send {Volume_Up}
return

^!down::
Send {Volume_Down}
return
Control-Alt-Up/Down for volume and M for mute, which is also set as extra buttons on my mouse so I don't actually have to press the hotkey at all.. change up the keystrokes if you prefer the function keys, easily done. There's also Media_Next/Prev/Stop, Media_Play_Pause and a bunch of others available to you as well.

http://www.autohotkey.com/docs/commands/Send.htm

  • Like 2
Link to comment
Share on other sites

I got this to work with play/pause in itunes, but it has to have the active window. Any way around this?

Ah -- I don't use iTunes myself but from what I've read in the past it can be a bit quirky when it comes to the keyboard. You can tell AHK to send a keystroke directly to a window or control. Something along the lines of:

 

DetectHiddenWindows, on  ; (Not positive, but you *might* need this for iTunes)
^!p::
IfWinExist, ahk_class iTunes
ControlSend, ahk_parent, {SPACE}  ; Simulates the space which should be play/pause
May need some fiddling, been years since I had a desire to look at iTunes, theoretically if you press ctrl-alt-p it'll send a space to the iTunes window, even if it's not in the foreground. Theoretically.

If you want to get cute you can also use "IfWinNotExist, ahk_class iTunes" to see if iTunes is even running, and if it's not, launch it via "Run".

http://www.autohotkey.com/docs/commands/ControlSend.htm

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.