views:

133

answers:

1

I don't want to actually MAKE the pong easter egg, but for anyone with Dreamweaver, try typing 'dreamweaver' into the color selection box to play a round of pong.

The bit that I want to know how it works is the bit at the end once you lose.

After your loss, it will immediately play a small tune, whether or not your volume is on. In fact, it plays whether or not you have speakers, which makes me think the sound card itself is playing the tune.

How can you achieve a similar effect, playing notes without sound or speakers, in vb.net?

I would imagine this requires P/Invoke, seeing as there is no obvious way inside the framework.

Thanks for your help!

I don't need a whole song, a simple beep or the ability to change frequency of the beep will suffice.

A: 

Perhaps this is what you are looking for:

http://msdn.microsoft.com/en-us/library/ms679277%28VS.85%29.aspx

VB.Net declaration:

<DllImport("kernel32.dll", SetLastError := True)> _
Private Shared Function Beep(ByVal dwFreq As UInteger, ByVal dwDuration As UInteger) As Boolean
End Function

But it may not work on 64bit XP, Vista, or Win7.

Chris Dunaway