• Register
0 votes
272 views

Problem :

In my current application I want to get the MS-Word and PDF files through the Storage Access Framework which works well on some of the devices I have worked upon however on the Samsung note 4 API 6 I am facing following error :

All apps associated with this action have been disabled, blocked, or are not installed

Please find below my Code:

Button.setOnClickListener(new View.OnClickListener() {
@Override 
public void onClickButton(View view) {
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.addCategory(Intent.CATEGORY_OPENABLE);
intent.setType("application/pdf,application/msword");
Intent i = Intent.createChooser(intent, "File");
getActivity().startActivityForResult(i, FILE_REQ_CODE);
}
});
6 5 3
7,540 points

Please log in or register to answer this question.

1 Answer

0 votes

Solution :

I had personally faced similar error while using the Intents. I had received the same error when I was attempting to declare an Intent globally. Please find below example :

public class MyTestClass{
// Class Variables in (BAD)
private Intent someTestActivity = new Intent(this, SomeTestClass.class);
@Override 
protected void onTestCreate(Bundle savedTestInstanceState){
        // Some Code below
    }
}

Then, I discovered that this issue was fixed when I made following change:

public class MyTestClass{
// Class Variables in (Not Bad)
private Intent someTestActivity;
@Override
protected void onTestCreate(Bundle savedTestInstanceState){
someTestActivity = new Intent(this, SomeTestClass.class);
    }
} 

There was no trace of this as an "error." I guess it is more of an OS-handled exception for incorrect usage of Intents.

9 7 4
38,600 points

Related questions

0 votes
1 answer 2 views
2 views
Problem: Please help me fix this dilemma “The file does not have a program associated with it for performing this action”?
asked Mar 29 tuhin1 47.2k points
0 votes
2 answers 33 views
33 views
Problem: Android obesity is associated with a higher incidence of all the following except A) heart disease. B) diabetes mellitus. C) hypertension. D) cancer.
asked Apr 12, 2020 ArifulIslam 7.5k points
0 votes
1 answer 279 views
279 views
Problem : I want to run the Eclipse JSF project on the Apache Tomcat on some other computer. I created the WAR file. But, when I try to deploy the WAR and open my Facelet page in Firefox, I usually face only the below error message: “This XML file does not appear ... first time when I am trying to run the JSF app without my Eclipse. How is this issue popping up and how can I fix the issue?
asked Jan 3, 2020 alecxe 7.5k points
1 vote
1 answer 2 views
2 views
Problem: Please help me to solve it out : no apps are installed to open this type of link
asked 4 days ago MUHAMMAD MUNEEB 80k points
0 votes
1 answer 158 views
158 views
Problem: I have recently started understanding Android Programming. I have some doubts about Androids compatibility. I am trying to understand whether my Android provides some sort of the compatibility I want to say either is it forward or backward compatible. Just like in Blackberry if I ... the Android SDK 1.5 then will that app properly work on any of the handsets having the OS 1.5 or higher.
asked Jul 13, 2020 Raphael Pacheco 4.9k points
0 votes
1 answer 10 views
10 views
Problem: How to solve this issue ? wrn assembly binding logging is turned off
asked Feb 26 Azlan2020 2.3k points
0 votes
1 answer 4 views
4 views
Problem: I am stuck during learning as I have already mentioned in my question someone please cooperate me to continue my project-Thanks
asked Mar 21 shamimkhan 15.1k points
1 vote
1 answer 21 views
21 views
Problem: I need help understanding this error: the activity must be exported or contain an intent-filter. your security settings have blocked an application signed with an expired or not-yet-valid
asked Mar 3 Muneeb Saadii 125k points
0 votes
1 answer 4 views
4 views
Problem: Please help me to solve it out : same or higher version of .net framework 4 has already been installed on this computer
asked Apr 1 rakib1 51.3k points
0 votes
1 answer 2 views
2 views
Problem: Can someone help me figure out how to solve this,"why is my phone not compatible with apps?"
asked 4 days ago Humaira ahmed 8.1k points