Android Question How to access Download Folder without any User intervention

GiovanniPolese

Well-Known Member
Licensed User
Longtime User
Hi.
I have the problem to access the Download Folder (or, alternatively, the Document folder). I have read previous posts, included one of mine, about using ExternalStorage library and I saw the difficulty to explain the problem. Therefore I am aware that a misunderstanding will arise on the question. BTW I also successfully tried the ExternalStorage example which works fine. The question may be misunderstood because it is not the matter of "accessing", but to do it without user's intervention. As a matter of fact, I have an App, with its graphical "standards" (colors, buttons etc.). It is weird to use the ExternalStorage library example "as is" because it has a completely different user interface. This is the point, and I don't see the way to use the ExternalStorage library for my needs. (Maybe it is impossible..) Resuming, let's fix the following:
1) I don't want to ask anything to the user. I don't want anything to appear. (Because I only want to access a the Download folder : thus there is nothing to ask to the user).
2) my goal is to copy the files of just one type (for example the "Download/*.jpg" files) to folders which are internal to the GetSafeDefaultDir of my App.
The final question is: is it possible or not?
Thanks in advance
 

drgottjr

Expert
Licensed User
Longtime User
i vote no. google does not like the idea of user non-intervention, especially as relates to system resources.
you can't think of this as a case of a trusted relationship between you and your user; the problem for google is
that it is a case of an untrusted relationship between an app and a user. if you can access a system resource
without telling the user what you're doing or finding out whether it's ok, a malevolent app could do the same thing.

we were told years ago to stop using external storage. google wants that area to be managed by the os. on its terms.
you don't indicate why you use the documents/files folder instead of the app's internal storage (over which you have
control), but you're paying a price for your choice.

that you don't like the externalstorage library's interface is a different issue. but in theory you could write a
different library with a different interface. or pay someone (the library itself may not be simple to modify. i'm
also assuming it's open source, but that may not be accurate).

it is possible to save files to documents/files with a contentresolver (ie, no library), but getting at that file
later without the help of the os is a problem.
 
Upvote 0

GiovanniPolese

Well-Known Member
Licensed User
Longtime User
Ok. Of course there is a reason for things being so. I can discuss a lot on these topics, but I understand that it is time lost, because things are so. Of course I have reasons to need to access a folder out of the App reserved space. Thanks.
 
Upvote 0
Top