This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

System Beep on messages recieved via VBScript

I recently had the need for an audible alert based on specific messages and found a code snippet to cause the system beep. It's just a command shell echoing the bell character, but I thought I would share it with the community incase anyone else is looking for something similar.

Just add the following two lines to your script when you want the beep:

Set oShell = CreateObject("Wscript.Shell")

oShell.Run "%comspec% /c echo " & Chr(7),0,false