Skip to content

Instantly share code, notes, and snippets.

@AKuederle
Last active August 29, 2015 14:14
Show Gist options
  • Save AKuederle/df9a2c2fad146ef539ca to your computer and use it in GitHub Desktop.
Save AKuederle/df9a2c2fad146ef539ca to your computer and use it in GitHub Desktop.
Simple autohotkey script to select one of two audio devices under Windows. Bit clumsy, but it does its job. Inspiration from: www.autohotkey.com/board/topic/2306-changing-default-audio-device/page-4
#+*F6:: ; assign hotkey (windows+Shift+F6)
Run, mmsys.cpl
WinWait,Sound
ControlSend,SysListView321,{Down 1} ; By changing the number behind Down the audiodevice can be selcted
ControlClick,&Set Default
ControlClick,OK
return
#+*F7::
Run, mmsys.cpl
WinWait,Sound
ControlSend,SysListView321,{Down 2}
ControlClick,&Set Default
ControlClick,OK
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment