PowerHi,
In my script i love to add notifications normally i use default beep sound. Few of my script which runs in background while i am working on something else i want to add few more sound notification in to them, So if any error occurred i get aware of them.
I found that windows Dot Net Library have few more extra sound notifications. That library get the notifications sounds those are configured in “Sounds” option in the Control Panel.
Like the Asterisk, Beep sound.
If you want to add sound notifications in to your scripts, you can use any of the below command listed below in to you script.
[System.Media.SystemSounds]::Asterisk.play()
[System.Media.SystemSounds]::Beep.play()
[System.Media.SystemSounds]::Exclamation.play()
[System.Media.SystemSounds]::Hand.play()
[System.Media.SystemSounds]::Question.play()
try them in your POSH console , you will love then
Thanks for reading.
Thanks!
Aman Dhally
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.