0

I want to know how to set volume with cmd but can't download software. I know it is possible because I had it but deleted it. opps

1 Answers1

0

Save this as a .VBS file and use as a template to do what you want. You can find more help about the SendKeys method here.

set WshShell = CreateObject("WScript.Shell")
WshShell.Run "%SystemRoot%\System32\SndVol.exe"
WScript.Sleep 1000
WshShell.AppActivate "Volume Mixer"
WshShell.SendKeys "{PGUP}" ' Turn the volume up by 20. If muted it will unmute it.
WshShell.SendKeys "%{F4}"  ' Alt+F4

You can call it from a batch file using cscript SetVol.vbs (or whatever name you used obviously).

Karan
  • 57,289