play a wav file
-
Not sure if there's anything built in ( for C# 2.0, I thought there was ), but the PlaySound API can be interoped for wavs, for mp3, you can use the Windows Media Player control.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog
-
Not sure if there's anything built in ( for C# 2.0, I thought there was ), but the PlaySound API can be interoped for wavs, for mp3, you can use the Windows Media Player control.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog
-
i know there is a playsound function and i read on msdn that it is on coredll.dll. the only problem is that i don'y have a coredll.dll.
rzvme
http://www.pinvoke.net/search.aspx?search=playsound&namespace=[All][^] says that it's there, and in winmm.dll. I expect it's really in winmm.dll.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog
-
You are looking for one of these functions :) [DllImport("Winmm.dll", CallingConvention=CallingConvention.Cdecl)] static extern int sndPlaySound(IntPtr buffer, int dwFlags); [DllImport("Winmm.dll", CharSet=CharSet.Ansi, CallingConvention=CallingConvention.Cdecl)] static extern int PlaySound(string filespec, int hModule, int dwFlags);
Luc Pattyn
-
Hi rzvme, Check this link (http://www.codeguru.com/csharp/csharp/cs_graphics/sound/article.php/c6143/[^]) out for a bare bones starter version. Hope this points you in the right direction.
Thanks and Regards, Aby