What does internal storage and external storage mean in android ? Ιs external storage a micro SDcard and internal storage phone memory ? If I need to write a file for my application, which is only my application needs (the user has no work to do with this file), then where should I write my file - in internal memory or external memory?
I think, if I write my file in SDcard (external memory) then when user pull out the SDcard the application will not be able to read the file. Is it right? If it is right then writing file in external memory will not fulfill my criteria. Because, my application has to check some data in the file several times and if in that particular moment the user pulls the SDcard out, my app can't achieve its goal.
And I need to write the file permanently (but if the user uninstalls the app, then the file should be deleted). So, which way should I go?
Have a look at this blog post about the correct way to use file storage in Android.
If you need to have access to the file all the time, internal storage is the way to go. But you shouldn't use big files in internal storage because many devices are very limited in storage space.
Files get deleted automatically on external as well as on internal storage when you use the Android built-in mechanisms to create the files in the first place. That is also explained in the post.