Excel vba – make a beep sound
I have been working on an Excel spreadsheet and wanted to make a beep into some VBA code. Turns out to be very simple as you just put the word beep into the code. For example:
If Range(”A1″) = True Then
Range(”A2″) = True
Beep
Endif
In this example, if cell A1 is set to True then cell A2 will also be set to true and a beep sound will be made.
If you want to play different types of beep depending on the condition have a look at the following
http://www.vbaexpress.com/kb/getarticle.php?kb_id=771
You can also play WAV files within a VBA macro but that looked a little more complex. Search on “Excel VBA play wav file” and you will find several examples.
Good luck
Ian
Did you enjoy this post? Why not leave a comment below and continue the conversation, or subscribe to my feed and get articles like this delivered automatically to your feed reader.

Comments
No comments yet.
Sorry, the comment form is closed at this time.