Kevinkun
(kevinkun)
June 28, 2021, 11:54pm
#5
we can download file to private dir with Web component, no need read or write permission.
1 Like
I don’t think so, but I like to be surprised and am curious about your approach (blocks).
Kevinkun
(kevinkun)
June 29, 2021, 8:18am
#7
Sorry my mistake.
It indeed need the write permission even if download to private dir.
I made this mistake, because I tested on other AI distro (wxbit), where the write permission not needed.
Yes, but furthermore it doesn’t seem to be possible (even with WRITE
permission) to download files to the privateDir
using the Web
component.
So again, show your blocks.
1 Like
What does this path have to do with the privateDir
(internal storage)?
Nothing !
As I said before, it doesn’t work with the Web
component.
2 Likes
Kevinkun
(kevinkun)
June 29, 2021, 12:54pm
#11
I tested on Wxbit (app.wxbit.com ), Web component can download to private dir, and with no write permission.
Maybe they modify the source code.
Kodular staff should do the same, i think.
1 Like
We are here on the Kodular community. So please test with Kodular .
When I test something, I basically do it on the original (→ AI2) and on Kodular.
On both of them it doesn’t work with the Web
component (and I doubt it works with other distros, regardless of the permissions issue) .
1 Like
vknow360
(Sunny Gupta)
June 29, 2021, 2:19pm
#13
Permission will be always asked:
* This method can throw an IOException. The caller is responsible for catching it and * triggering the appropriate error event. * * @param webProps the captured property values needed for the request * @param postData the data for the post request if it is not coming from a file, can be null * @param postFile the path of the file containing data for the post request if it is coming from * a file, can be null * * @throws IOException */ private void performRequest(final CapturedProperties webProps, final byte[] postData, final String postFile, final String httpVerb, final String method) { // Make sure we have permissions we may need if (saveResponse & !havePermission) { final Web me = this; form.askPermission(new BulkPermissionRequest(this, "Web", Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE) { @Override public void onGranted() { me.havePermission = true;
2 Likes
And for this path →
WRITE
permission is required in any case.
1 Like
Even with the ExtendedDownloader
extension from @Atom_Developer it does not seem to be possible to download directly to the privateDir
.
1 Like
Thanks for this extension.
How to delete the files on ASD directory?
How Can I share a file after any given file has been downloaded?
Thanks for your support!
These questions don’t actually relate to my extension, but nevertheless:
3 Likes
Thanks for your time and orientation on this.
Regards,
MS
produksi
(puspelka)
October 21, 2021, 8:00am
#20
Where is “Path” component in this extension ?
dora_paz
(Dora)
October 21, 2021, 8:04am
#21
It isn’t a component, it is a procedure, look example in…
Here is an extension to download any file (jpg, png, txt, apk, zip, mp3, …) to the ASD (app-specific directory) without WRITE_EXTERNAL_STORAGE permission.
Version 1 (Dec 13, 2020):
de.bodymindpowerDownloadToASD.aix (removed)
Version 2 (July 16, 2021):
DownloadToASD.aix (7.5 KB)
Version 3 (Aug 24, 2021):
Here is a special version of the extension, that does not show a notification while / after downloading.
DownloadToASD_notifHidden2.aix (7.6 KB)
Note: Use this version of the extension on…
2 Likes
Rahul9
(Rahul)
May 22, 2022, 3:15am
#22
Please provide aia and test apk of this
This file
How can i make it (.aix)?