I have released an App which user can take photo in it.I do this to capturing photo:
File file = new File( _path );
Uri outputFileUri = Uri.fromFile( file );
Intent intent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE );
intent.putExtra( MediaStore.EXTRA_OUTPUT, outputFileUri );
startActivityForResult( intent, 0 );
and also I added this permission to manifest:
<uses-permission android:name="android.permission.CAMERA" />
I tested my App on Android2.3.5
and Android3.0
,and it works fine.But when I run my App on Android4.0.3
,it crashes:
android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.media.action.IMAGE_CAPTURE (has extras) }
How I can solve this problem?