I can not understand why the file is not created in the files folder of the internal directory of the application. I do according to the instructions from Android Developers.

 File file = new File(context.getFilesDir(), "hello"); File file = new File(getFilesDir(), "hello"); File file = new File(getApplicationContext.getFilesDir(), "hello"); 

The file is not created, tried differently, in any way. Through the FileOutputStream stream, the file is created, but how to create the file using the File class? And how to create a file in your created directory?

    1 answer 1

    An object of type File to create is not enough. You also need to force the file system to write the file to memory: file.createNewFile();