Hi
Anybody Know the solution for my issue please help me.
Issue:
How play the remote url videos in android app .Am try two kind of way
but is not working correctly please find my two kind of codes.
vid="http://www.tamilclips.net/components/
com_contushdvideoshare/videos/24_hd.mp4"
1. VideoView videoView = new VideoView(this);
setContentView(videoView);
MediaController mc = new MediaController(this);
mc.setAnchorView(videoView);
mc.setMediaPlayer(videoView);
videoView.setMediaController(mc);
videoView.setKeepScreenOn(true);
videoView.setVideoPath(vid);
videoView.start();
2. Uri uri = Uri.parse(vid);
Intent intent = new Intent(Intent.ACTION_VIEW, uri);
intent.setDataAndType(uri, "video/mp4");
startActivity(intent);
The first one not working but the second one is working but the
android phone having streaming player option otherwise its show the
video can't played error.
--
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