views:

258

answers:

2

Dear all,

I want to play a sound while my splash screen gets data from the server.

The sound file is not too large. I want something like when you start your computer you hear the MSWinXP welcome sound and that while establishing your account.

How can I do that?

thnx

A: 

Like, in what kind of language? OS? where? what?

DFectuoso
Eng.Basma
+2  A: 

Use System.Media.SoundPlayer. You may need to put this code in Form_Load instead.

    private void button1_Click(object sender, EventArgs e)
    {
        System.Media.SoundPlayer player = new System.Media.SoundPlayer();
        player.SoundLocation = @"C:\Windows\Media\chimes.wav";
        player.Play();
    }
m3rLinEz