Playing audio file for specific time
问题 Guys i able to play audio file using Mediaplayer. But i need to play a audio file for specific time. Eg: play audio1.mp3 till 5 minutes. The audio file is of 10 seconds only.But it should keep playing till 5 minutes. 回答1: try this mediaplayerplayer.setLooping(true);<--- this lets the audio to loop... and this is the countdown timer MyCount counter; Long s1; counter= new MyCount(300000,1000); counter.start(); public void asdf(View v){ <---- method for onclick of buttons pause and resuming