Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

Why embeded .wav files played with soundplayer on winXP generate strange noise and some time crashes, but its ok on Win7?

$
0
0

There is a hello.wav that I embeded in my program, and played with below code:

Stream WavStream = Assembly.GetExecutingAssembly().GetManifestResourceStream("hello.wav");

System.Media.SoundPlayer WavPlayer = new System.Media.SoundPlayer();

WavPlayer.Stream = WavStream;

WavPlayer.Play();


this program is OK on Win7 but when it run on WinXp, sometime there is noise, and seriously it makes crashes in speaker, why?



Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>