Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a Microsoft Comfort Curve keyboard (KU-0459). It features a set of buttons for volume control. The interesting one is "mute".

I also have a set of USB speakers (Logitech S-150), and a set of headphones with the usual 3.5 mm green/pink jacks going to my on-board sound card.

I am on Windows 7 Ultimate.

I am able to selectively mute the speakers by going into Control Panel -> Sounds -> Playback tab -> Right click speakers -> Disable. I'm very lazy, and I want all of this "clicking" to be done automatically whenever I press my Keyboard's mute button.

If your answer is "AutoHotkey", it would be very nice if you could supply the .ahk script itself

share|improve this question
up vote 2 down vote accepted

I have written many AutoHotkey scripts to navigate the Control Panel, so I've got you covered! The following script requires that Show Disabled Devices is on

show disabled devices

and that Speakers is Enabled when starting the script.

Note: in my case, Speakers was the 2nd item in the list, so I set the variable speakers to 2.


enabled = 0
speakers = 2

    enabled := !enabled

    Run, control /name Microsoft.Sound
    WinWaitActive, Sound

    Send, {Down %speakers%} ;Speakers
    Send, +{F10} ;Right click

    if (enabled = 1)
        Send, d ;Disable
        Send, e ;Enable

    WinClose, Sound


If you are unfamiliar with AutoHotkey or would like a precompiled version of the script, I can provide one that takes the speaker variabled as a parameter. Just let me know. :)

share|improve this answer
Thank you for the script! It does work if mapped to another key, say, ^m. However, it doesn't seem to respond to Volume_Mute. Nor does the AHK recorder appear to capture it, for that matter. – Superbest Feb 23 '12 at 22:26
In that case, you can try to find the scan code for your Mute key. See my answer here for instructions: (Setup; steps 4-10) – iglvzx Feb 23 '12 at 22:28
Thank you! For anyone else- with the keyboard model I have, the mute key is SC120, you would use it by replacing Volume_Mute:: above with SC120::. – Superbest Feb 24 '12 at 0:15

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .