ah yeah,
i copied the files with the desktop pc to the LogFiles folder
so if the files are copied with the App to this folder it will work?
But with Android 10 the files are also not listed?!
ah yeah,
i copied the files with the desktop pc to the LogFiles folder
so if the files are copied with the App to this folder it will work?
But with Android 10 the files are also not listed?!
Yes, but you cannot overwrite / replace existing files, that were not created by the app. So you have to change the file names.
ok, i will try it
i got it working:
File (received via Bluetooth) is written to ASD -> work on Android10
If File is ok it's copied to Documents/Logfiles -> work on Android 10
So now i want to open this file in a CustomWebview (with file Access and Js)
for that i copy the file from Documents/Logfiles to ASD/files/Webview (where the index.html is saved)
but when opening the webview the App crash and close -> Android 10
this was working before all the file changes
edit: the file is not copied to webview folder (is ASD)
test's on Android 11 are coming later -> i'am have not access all the time
i think i got it running.
But i noticed a little Problem:
Creating folders with Android 10 requires Permission for Write external Storage (same for copy?)
But with Android 11 i get an Error message that this permission is not allowed.
is there a nice work around?
Creating folder, where?
Show your relevant blocks.
/storage/emulated/0/Documents/LogFiles
i also cant copy to this location
i have to use the permission:
Everything for Android 10
edit:
for test i removed the App and Documents/LogFiles
with permission the folders are created
without permission the folders are not created
did you try a relative path /Documents/LogFiles
together with the scope Shared?
Taifun
that is working (when the app is opened second time)
any idea why i have to open it twice?
That is workingπ
i think i'am going crazy
now everything is fine on Android 10
but on Android 11 nothing works, i just get following error:
No folder is created!
Ankes examples are working with Android 11. And i cant find a difference.
@Anke what is the "call exist"?
Here is my aia, maybe someone find an issue
BlControl(1).aia (967.9 KB)
There are two options:
With the β File
component:
Without storage permissions (on Android 11+) using the β FileTools
extension:
I'd prefer the second one.
thank you @Anke. i will try it.
i found the difference between your filetest and my app
default File scope in Screen settings
you had "legacy"
i had "App"
i thought legacy mode wont work in the future?
DefaultFileScope = Legacy
is essentially STILL responsible for which storage permissions are declared in the Manifest. WRITE_EXTERNAL_STORAGE
is ONLY declared in the Manifest if DefaultFileScope
is set to Legacy
in the Designer. And this even under Android 11+, which of course makes no sense, since this permission is no longer available under Android 11+.
I have pointed this out countless times.
Here are all permissions declared in the Manifest of your app (after setting DefaultFileScope
to Legacy
):
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_FILES"/>
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
<uses-permission android:name="android.launcher.permission.INSTALL_SHORTCUT"/>
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.RECORD_AUDIO"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.webkit.resource.VIDEO_CAPTURE"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
<uses-permission android:name="android.webkit.resource.AUDIO_CAPTURE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
<uses-permission android:name="android.permission.CAMERA"/>
<uses-permission android:name="android.permission.BLUETOOTH"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_DOWNLOAD_MANAGER"/>
Thank you @Anke for your Help.
It's now all working as expected.
Maybe one little thing:
Would all this file Stuff work under Android 12? Or will it be a never ending story?
i don't have access to an Android 12 Phone
Yes.
I checked it on a Pixel 4XL (Android 12).
Nice, thank you so much