question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Android install and No app associated with this mime type issue

See original GitHub issue

Hey, Firstly, thanks for your hard work! Ios is working beautifully and can’t wait to get this up on android…

First issue The readme installation instructions for android number, Copy android/src/main/res/xml/file_viewer_provider_paths.xml to your project res/xml/ directory I can’t find that path in my project. screen shot 2018-10-30 at 8 15 46 am

Second, I can’t open a docx on android. I’m assuming due to not completely step four of the installation. But… ` // // const path = // absolute-path-to-my-local-file. FileViewer.open(filePath) .then(() => { console.log(‘success’) // success }) .catch(error => { // error console.log(‘Error viewing document’, error) })

` screen shot 2018-10-30 at 8 16 00 am

I should also note. When attempting to open a PDF, I get a success and can view the document.

I am not using RNFS but RNfetchBlob as it supports more of what I’m doing with streams.

UPDATE: It may appear android just doesn’t support docx. If you can verify this, lets get a PR stating that in the docs to save newbies like me some time 😉. Thanks!

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:24 (4 by maintainers)

github_iconTop GitHub Comments

15reactions
Salem-Abderaoufcommented, Mar 8, 2022

I solve this issue by adding <queries> <intent> <action android:name="android.intent.action.VIEW" /> <data android:mimeType="*/*" /> </intent> </queries> to androidManifest.xml and rebuild the app . Also try to install app that read the specific file like csv reader for csv files

6reactions
vinzscamcommented, Dec 15, 2021

Hi @thexdd! Sorry, I missed the latest comments on this issue! So, regarding the first point (copying file_viewer_provider_paths.xml), this is something old which was required before autolinking was introduced. I don’t think you need to do this anymore. The second issue (No app associated with this mime type), it could be related to Android devices targeting Android 11+. I’ve recently upgraded the documentation here https://github.com/vinzscam/react-native-file-viewer#extra-step-android-only

Let me know if this helps! Otherwise feel free to open another issue sharing details about the issueissue, a snippet of your code + information regarding devices or simulators where you are experiencing the issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

React native file viewer No app associated with this mime type
Just try to add line in AndroidManifest.xml at the end but before the manifest closing as mentioned below
Read more >
Allow applications to define MIME type to file ... - Issue Tracker
To fix this problem, please allow a tag to be included in the application's manifest defining a custom file extension and the corresponding...
Read more >
How to fix This file does not have an app associated with it for
Please install an app or, if one is already installed, create an association in the Default Apps Settings page. How to fix below...
Read more >
This File Does Not Have an App Associated with It FIX [Tutorial]
This File Does Not Have an App Associated with It for Performing This Action Solution [Tutorial]On a Windows based computer the following ...
Read more >
How to tell Android to use an application to open a mime type?
Hi again: My new (but, I'm sure, not last) problem with my rooted T1 android ebook is: How could I associate a mime...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found