I’m writing an app that saves files. For a long time, I was stumped as to why it was not saving these files in the app directory since I couldn’t see the files in Windows Explorer:
(Either SD card or internal storage)
Yet, in code, I could see the files exist. So I decided to check via Device File Explorer in Android Studio, and the folder structure is different, and (more importantly) the files are there:
This is not blocking me, it’s more just a curiosity thing.
Question
What am I misunderstanding? I would maybe explore the idea that I’m perhaps looking in the wrong place but I ran a search in Windows Explorer and it found nothing.
Is Windows Explorer unable to navigate the android files, for some reason? Why do these folder structures not look the same.
3
Answers
I think it’s a file permission issue.
Probably folder you are writing doens’t permits to Windows to see her.
You can compare you issue with database SQLite files.
If you use Android studio > Device file explorer, you can see database APP files and also download them.
But with Windows you will not see databasases files ever!
I think that android studio doesn’t save your phone files on windows , it just reads them directly from your phone and shows them to you .
Your first picture shows /storage/emulated/0/Android/data/com.mycompany.###/files.
(Your PC names this Internal but you -should- know that Android considers it External storage)
The picture of Device File Explorer shows /data/data/com.mycompany.####/files. (This is what Android considers internal).
So you are comparing not the same paths.
Device File Explorer can show both.
Windows can only show the first path. Never the second.
Device File Explorer can show both.