Hello Everybody,
I want to use MediaPlayer play a file mp3 or video with Streaming. I have
code:
               try {
                    String path = "http://codpro.tk/test.mp3";;
                    mediaPlayer = new MediaPlayer();
                    mediaPlayer.setDataSource(path);

mediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);
                    mediaPlayer.prepare();
                    mediaPlayer.start();
                } catch (Exception e) {
                    Toast.makeText(PlayLocalFiles.this, e.getMessage(),
Toast.LENGTH_LONG);
                    txtStatus.setText(e.getMessage());
                }
I got error message: "Prepare failed.: status=0x1". I have been search for
slove it and repair it. But I didn't solve the problem yet.

Could you please help me?
Thank you,
-- 
Thanh, Le Cong <http://fit.utehy.edu.vn/codepro>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to