Ashutosh Tripathi

Ashutosh Tripathi

  • NA
  • 44
  • 11.6k

Audio in website from c# CODE BEHIND PAGE.

Jul 5 2015 6:33 AM
I want to know how to put a audio in website by using c# on code behind page.
I had used some code like
 
 
System.Media.SoundPlayer player = new System.Media.SoundPlayer(Server.MapPath("~/available.wav"));
player.Play();
 
 
it is working fine on my local host but not working after hosting on server.
 
The main motive of my work is to play a sound like "Seat is available"  after checking database for available seat and if seat is not available than it play a sound like"Seat is unavailable". All work is done on button click event.
 
I need the solution as soon as  possible, so please help me.

Answers (2)