sndPlaySound function problem

A

Ansh

i want to play a .wav file using sndPlaySound and PlaySound function
but both function doesn't works in the expected way... i just hear a
click sound after execution of these functions.... not the original
recorded sound of .wav file.... on the other hand when i make use of
wave functions to play sound it works fine... can anybody tell that
what exactly the problem is??? all docs i read suggests that these
functions works fine if we hav eto play only a single wave file... but
this doesn't works in my case.... help me...
 
L

Lyny

Try this: (My testBox1.Text is a wav file name with the path)

System.Media.SoundPlayer player = new
System.Media.SoundPlayer(textBox1.Text);

player.Play();
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top