I want to play .3gp video file in my android tablet. i tried below code, but it throws an error message. How can I play with default video player in android?
String movieurl = root + "/" + fileNameTextView.getText().toString();
Intent intent = new Intent(android.content.Intent.ACTION_VIEW);
Uri data = Uri.parse(movieurl);
intent.setDataAndType(data,"video/3gpp");
startActivity(intent);
And this is the error message:
11-15 13:47:11.060: E/AndroidRuntime(23061): android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=/mnt/sdcard/DCIM/Camera/VID_20121002_174209.3gp typ=video/3gpp }
I have changed the String movieurl by adding "file:///" to the beginning:
String movieurl = "file:///" + root + "/" + fileNameTextView.getText().toString();
and that fixed the issue.