The button click method mentioned below, can be used to start playing an audio file. However, once it starts it cannot be paused, if I click the button again the song will start to play again, from the beginning. Please let me know the way to stop it using Enter Key.
private void btn_reproducir_Click(object sender, EventArgs e)
{
WindowsMediaPlayer myplayer = new WindowsMediaPlayer();
myplayer.URL = @"C:\song.mp3";
myplayer.controls.play();
}
