AutoHotKey script for keyboards lacking media keys


Recommended Posts

I have a keyboard that lacks media keys - play/pause, back, forward, stop, and volume control keys. But I can't be arsed to buy a new keyboard, and frankly I'm tired of clicking on controls on my desktop to change the volume (and besides, Windows 8 is the first Windows with a OSD built-in - finally).

So I found this sample AutoHotKey script and modified it for my needs. Code is below. For the uber lazy I've also attached a compiled exe. The below comments should easily tell you what the keyboard combinations are ;)

Drop a shortcut in %APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup to start upon login.

;; Virtual Media Keys
;; Based on http://frugalcoder.us/post/2011/10/07/Mapping-windows-volume-for-keyboards-without-media-keys.aspx
;; Map WIN + F5 to <<
#F5::Send {Media_Prev}
;; Map WIN + F6 to Play/Pause
#F6::Send {Media_Play_Pause}
;; Map WIN + F7 to >>
#F7::Send {Media_Next}
;; Map WIN + F8 to Stop
#F8::Send {Media_Stop}
;; Map WIN + F9 to Volume Down
#F9::Send {Volume_Down}
;; Map WIN + F10 to Volume Up
#F10::Send {Volume_Up}
;; Map WIN + F11 to toggle mute
#F11::Send {Volume_Mute}

Virtual Media Keys.zip

Link to comment
Share on other sites

I happened to do exactly the same thing the other day when i received my Filco. I use Ctrl+Alt+Arrow keys for different functions though.

One thing i am looking to do is setup an OSD for the volume control, there's a few already out there that just need modifying to suit.

Link to comment
Share on other sites

This topic is now closed to further replies.