Hyperlinks to files in the Android 10 file system
2
votes
0
answers
1735
views
I seem to have tripped over a rarely attempted task in relation to links to files on the Android file system. There is one other question about this from 2013 and it was never answered (https://android.stackexchange.com/questions/39554/how-to-hyperlink-to-file-in-kingsoftoffice) .
I want to create a link to a file in the Android file system (any file e.g. a PDF) within a document (e.g. for Excel or Word).
I have my reasons which can be explained later if there is a solution.
In the absence of a means to create such links in the apps, I obtained the pathname for a PDF on my Android phone and copied it to a Word-App doc on OneDrive. On my PC, I added a hyperlink to the doc linking to the Android pathname. Back on the mobile, with the updated doc open and the link visible, tapping the link resulted in the message -:
*"Can't open. There's no web browser installed for this user profile, so the page couldn't be opened"*
It seems the link is treated as an external link requiring a browser when Android needs to know that the PDF has an app it can use. Or it needs to open the default browser (Chrome) where the browser needs a PDF viewer extension, perhaps.
Otherwise, I don't know Android well enough to know where to go from here.
10/04/2023
Update
An example of the pathname is -:
/storage/emulated/0/Download/xxx.pdf
I have found that prepending "file://", the added text just disappears on 'save' leaving the above pathname unaltered.
On changing to
http://storage/emulated/0/Download/xxx.pdf
the "http:/" remains in place and the error message changes to "Cannot display PDF (filename.PDF cannot be opened)"
I deduce from this that the system recognises the hyperlink to the file and can extract and "understand" the filename but possibly can't find it or does not have permission to display it.
Asked by theHeatingEngineer
(21 rep)
Apr 9, 2023, 04:02 PM
Last activity: Apr 12, 2023, 11:20 AM
Last activity: Apr 12, 2023, 11:20 AM