Read CSV file in shared Documents foder

Does not require a full path

1 Like

Hi RAMDO Thank you for your answer
unfortunately the got text function still does not read in files and does not even activate.
The value of Label1.Text is always null

Use the extension

Read this, it may help you

Hi RAMDO

immagine

…the value of Label2.text is always null…

1 Like

If the csv file was not created by your own app, then you have to use SAF to read it
See also

Taifun

1 Like

Do you have a txt or csv file?
Make sure you write the file name literally

file type cvs but i also tried with a normal file with .txt extension
If you want to try it create a file in the documents folder and try to read it

1 Like

It works fine for me
Verify that a file exists

Hi RAMDO
for now i have solved it with SAF as suggested by taifun. But later I try to understand why efile doesn’t work for me.
Thank you so much

What is your Android version?
For me
Android version 8

my is 11 and 12

1 Like

this is the reason

I imagined

1 Like

Hi

How do I save a file inside / storage / emulated / 0 / Documents.
I tried like this but it does not save and does not give error

Thx

Please read the thread to learn about its usage:

Hello
I’ve read 1000 times but haven’t found the solution.
I need to export tinydb to csv table and save files to shared documents folder
I tried to do this but it doesn’t work
does not save

You forgot to provide a screenshot of your relevant blocks

Taifun

I read from tinydb database and I want to save in csv format on documents folder

SAF doesn’t work with file paths.
You need to open saf picker dialog and ask user to give your app access to Document dir. Only then you can create an empty document (not file ) there.