I have a mp3 file in my android mobile, lets it's a xyz.mp3 somewhere in my sdcard. I want to play it through my application. Please help me I have no idea about it.
相关问题
- How can I create this custom Bottom Navigation on
- Can we recover audio from MFCC coefficients?
- Bottom Navigation View gets Shrink Down
- How to make that the snackbar action button be sho
- Is there a way to play audio on a mobile browser w
相关文章
- android开发 怎么把图片放入drawable的文件夹下
- android上如何获取/storage/emulated/下的文件列表
- androidStudio有个箭头不认识
- SQLite不能创建表
- Windows - Android SDK manager not listing any plat
- Animate Recycler View grid when number of columns
- Why is the app closing suddenly without showing an
- Android OverlayItem.setMarker(): Change the marker
@Niranjan, If you are using a raw file from res/raw folder, ie., reading a file stored inside the project, we can use:
If you have to use from SD card:
See this related question: MediaPlayer issue between raw folder and sdcard on android
Simply you can use
MediaPlayer
and play the audio file. Check out this nice example for playing Audio: