Advertisement
Guest User

Untitled

a guest
Nov 13th, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Load required assemblies
  2. [void] [System.Reflection.Assembly]::LoadWithPartialName("System.Speech")
  3.  
  4. # Set Volume
  5. Function Set-Speaker($Volume){$wshShell = new-object -com wscript.shell;1..50 | % {$wshShell.SendKeys([char]174)};1..$Volume | % {$wshShell.SendKeys([char]175)}}
  6. Set-Speaker -Volume 50
  7. [audio]::Mute = $false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement