Skip to content

Instantly share code, notes, and snippets.

@ino46
Created March 27, 2009 15:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ino46/86732 to your computer and use it in GitHub Desktop.
Save ino46/86732 to your computer and use it in GitHub Desktop.
Dim objWshShell
Set objWshShell = WScript.CreateObject("WScript.Shell")
objWshShell.Run "control.exe mmsys.cpl ,1"
Sub soundkill()
objWshShell.SendKeys "{DOWN}"
WScript.Sleep 500
objWshShell.SendKeys "{TAB}"
WScript.Sleep 500
objWshShell.SendKeys "{BS}"
WScript.Sleep 500
objWshShell.SendKeys "{DOWN}"
WScript.Sleep 500
objWshShell.SendKeys "~"
WScript.Sleep 500
End Sub
Do Until objWshShell.AppActivate("サウンドとオーディオ デバイスのプロパティ")
Loop
objWshShell.SendKeys "{TAB 3}"
WScript.Sleep 500
objWshShell.SendKeys "{DOWN 2}"
WScript.Sleep 500
Call soundkill()
Call soundkill()
Call soundkill()
Call soundkill()
objWshShell.SendKeys "~"
WScript.Quit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment