Click here to Skip to main content
15,662,823 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi.Iwant to play mp3 or any type of sound on clicking a particular button in my web page..If any one knows about this plz send me the code at

Thanking You...
Updated 24-Nov-11 23:01pm

Hi checkout this link[^]

hope it helps!

mark this answer if it solved your problem

Share this answer
You can use Windows Media Player control:[^],[^].

You can find wrappers for 3rd-party or Open Source players. For example, look at one for VLC:[^],[^].

Now, low-level: please see this CodeProject article: A low-level audio player in C#[^].


This is the updated useful information on the VLC component binding for.NET:[^],[^],[^].

Notably, you can find material for using the component for both WPF and System.Windows.Forms.

Share this answer
Try using this html5 tag:

<audio src="song.ogg" controls="controls">
Your browser does not support the audio element.

For your reference:[^]

Please mark this as correct solution if it fixed your problem.

Best regards,
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900