Answers for "play mp3 android java"

0

play mp3 android java

MediaPlayer mediaPlayer;
//In the onCreate Method
mediaPlayer = MediaPlayer.create(this, R.raw.alarmclockbuzzer);
//Sound file goes in "raw" folder in "res" folder
mediaPlayer.start(); //plays the mp3 sound (doesn't need to be in oncreate)
Posted by: Guest on October-01-2020

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language