No Activity Found To Handle Intent - Android.intent.action.open_document
I am trying my hand on Storage Access Framework of android 4.4 I have developed a dummy app which fires an intent on start of the activity. Intent intent = new Intent(Intent.A
Solution 1:
Add a mime type, or simply intent.setType("*/*").
This seems to be a known issue. setType() is required.
Edit: you also need to add android:enabled="true", note that you should reference it from values and not directly so as only to enable it for >=kitkat. So android:enabled="@bool/is_kitkat", <bool name="atLeastKitKat">false</bool> in /res/values/ and <bool name="atLeastKitKat">true</bool> in /res/values-v19/
Solution 2:
To open all files add this line:
intent.setType("*/*") ;
and if you need to filter to display images add this line:
intent.setType("image/*");
Solution 3:
Just cast your intent, like,
Intentintent=newIntent("android.intent.action.GET_CONTENT");
((Intent)intent).addCategory("android.intent.category.OPENABLE");
((Intent)intent).setType("*/*");
Post a Comment for "No Activity Found To Handle Intent - Android.intent.action.open_document"