Whenever trigger a messagebox used in my C# program I get a very annoying beep from my computer. How do I disable this beep using C# code.
The code I am using is very simple.
MessageBox.show("text");
From the searching I've done it looks like the beep is hardwired into the Win32 message box function:
So you need to either write your own method or stop the beep in the hardware. The former will work for everyone, the latter just for you.
This is going to sound weird until you have tried it. Open your command prompt, type:
net stop beep
I did a quick google and found 4 other ways:
(from here)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With