Error 703... unable to play .mp3 file

21.6k Views Asked by At

I am building an app using App Inventor in which I need to play some sounds on button click. When I click button once it gives me

error 703: unable to play file

But on the next time, the sound is played.
Can anyone help me with this error?

2

There are 2 best solutions below

1
On BEST ANSWER

Done it. I just initialized sound component with every file at screen initialize. Now its working fine.

1
On

Try the below code,it works fine for me.

Uri b = Uri.parse(uri);
MediaPlayer mp = MediaPlayer.create(context,b);             
mp.start();