Pocket PC and PlaySound()

N

niv

Hello,

I have tried using the PlaySound method to play a wav file
from an asp.net mobile web application and c# with no luck.

First off the Dll Import file that I keep seeing is
coredll. When I place this filename into the DllImport
statement, the application generates an error.

So I used winmm.dll instead, no errors are generated but
nothing happens. The application seems to just go through
the PlaySound method. I have included the code below.
Please let me know if you have any information regarding
this.

Thanks
niv
[ DllImport("winmm.dll",
EntryPoint="PlaySoundW") ]
private extern static int PlaySound
(String lpszName, int hModule, int dwFlags);

private void Command1_Click(object sender,
System.EventArgs e)
{
int hResult = PlaySound("\\Windows\\Alarm1.wav",0,0);
}
 

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

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top