473,325 Members | 2,816 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Playing wave sound file C# ASP .Net

Hi,

I'm trying to play a short wave file in my C# asp .Net application when the user clicks on a button. Can anyone help me to do it please?

thanks & regards,

M.F.
Feb 7 '07 #1
1 4791
Hi,

I'm trying to play a short wave file in my C# asp .Net application when the user clicks on a button. Can anyone help me to do it please?

thanks & regards,

M.F.


Hello,

I have once done that succesfully using PInvoke calls.

Try to use the PlaySound() function from the coredll.

Check out the following link:
http://www.pinvoke.net/default.aspx/coredll.PlaySound

Cheers
Feb 8 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Brian Basquille | last post by:
Hello all, What is the syntax for simply playing a WAV file in your program? Am learning VB and have two VB books but don't wanna root through them to find the code. Any help would be much...
6
by: Xanax | last post by:
Hi all, I need to produce a sine wave and use the WaveOut APi to sound it on my sound card. I also need to compute Fast Fourier Transform to modify the Sine wave. Any ideas on where to start or...
1
by: Peter Schmitz | last post by:
Hi, I'm just trying to play a *.wav file, making use of the unmanaged function "sndPlaySoundA" in winmm.dll, but I still got one question: How can I avoid, that the sound file itself has to be...
4
by: vikram | last post by:
in a stereo type of wave file i want to know what is this left & right info in a wave file??? how do i read the left & right info from a .wav file to a buffer..
7
by: Lee Moody | last post by:
I just want quick and easy way to play a .wav file out the standard sound device. It could even be as simple as activating a sound assigned to an existing windows sound event. Any suggestions?...
5
by: m.topczewski | last post by:
Hello, I'm a beginner in c++, i have to write a program that will take couple of segments from one wave file, and store them in another wave file to be played back later. Here's the code i have...
1
by: Hitchkas | last post by:
I want to access a wave file's sound data buffer, manipulate the sound and attach the processed buffer back into the wave file using C#. Are there any C# sample codes showing how this can be done?...
0
by: Simrat Kaur Sandhu | last post by:
hello friends can anybody tell me how to read data from a wave file.. i have writen code as ... class file { private: FILE *fp; char id; char *sound_buffer; //four bytes to hold 'RIFF' long...
0
by: Karthik | last post by:
Hi, I want to record a sound wave from a mic and at the same time invert it and play the inverted wave.My code goes as follows, however nothing is written into the E:\inverted.wav file.Thanks in...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.