1

I am going to be downloading audio files to the device's internal memory. At a later time I would like to play this audio with a MediaPlayer. In the "Media Playback" guide on the developer site it mentioned using a "URI". Is there any way I could just use the filename of the file in the internal memory? How can I play saved audio?

Flynn
  • 5,903
  • 7
  • 38
  • 55

1 Answers1

0

To get the URI from a file path this may help:

it looks like

Uri.parse(new File("/sdcard/cats.jpg").toString()) should do the trick.
Community
  • 1
  • 1
Alan
  • 1
  • 1