BennoDual
BennoDual

Reputation: 6259

Increase Volume of Beep

I use this code to generate a Beep:

[DllImport("kernel32.dll")]
public static extern bool Beep(int frequencyHz, int durationMs);

private void DoBeep() {
    Beep(800, 500);
}

Now, I am searching for a way to increase the volume of the Beep. Can someone help me about that, please?

Upvotes: 0

Views: 2784

Answers (2)

Krumelur
Krumelur

Reputation: 32497

The Beep function was designed for ancient (early 90s) hardware that included a separate sound chip aside from the normal sound card. This sound chip could basically only emit tones, not true sounds. Nowadays, Beep is simply an alias to MessageBeep.

To adjust the volume of MessageBeep, you should adjust the sound volume for your program.

Upvotes: 0

MikeS159
MikeS159

Reputation: 1964

If you are referring to the BIOS beep, there is no way to adjust volume. It is really designed for testing and debugging hardware setups. You could try MessageBeep which uses the default sound device (i.e. speakers). https://msdn.microsoft.com/en-us/library/windows/desktop/ms680356%28v=vs.85%29.aspx

Upvotes: 2

Related Questions