Hello.
Thank you DonManfred for your quick answer.
My application has to read 3 files at startup.
In case they don't exist, I use the instructions below to create them.
And the Access Denied error message appears at the instruction "" LV.TextWriter1.Initialize(File.OpenOutput(Directory01,FileName01,False))
My instructions are:
Repertoire01="/storage/emulated/0/Android/data"
Repertoire02="/storage/emulated/0/Android/data/Sauv"
Repertoire03="/storage/emulated/0/Android/data/b4a.example/MesTel"
LV.TextWriter1.Initialize(File.OpenOutput(Repertoire01,NomFich01,False))
LV.TextWriter1.WriteLine(DateInit1)
LV.TextWriter1.Close
LV.TextWriter1.Initialize(File.OpenOutput(Repertoire02,NomFich02,False))
LV.TextWriter1.WriteLine(DateInit1)
LV.TextWriter1.Close
LV.TextWriter1.Initialize(File.OpenOutput(Repertoire03,NomFich03,False))
LV.TextWriter1.WriteLine(DateInit1)
LV.TextWriter1.Close
My Application is published on playStore.
Here is the Manifeste
'This code will be applied to the manifest file during compilation.
'You do not need to modify it in most cases.
'See this link for for more information:
Basic4android v1.8 introduces a new tool named Manifest Editor. Every Android application includes a file named AndroidManifest.xml. This is an XML file that describes the application for the OS. It includes elements such as the application components (activities, services and receivers), icons...
www.b4x.com
AddManifestText(
<uses-sdk android:minSdkVersion="5" android:targetSdkVersion="30"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<supports-screens android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:anyDensity="true"/>)
SetApplicationAttribute(android:icon, "@drawable/icon")
SetApplicationAttribute(android:label, "$LABEL$")
SetApplicationAttribute(android:requestLegacyExternalStorage, True)
'End of default text.:
FerGeoRi