I receive the image on means of sockets. The image appears in the gallery because the system was informed about the new file by the line:
MediaStore.Images.Media.insertImage(getContentResolver(), file.getAbsolutePath(), file.getName(), file.getName()); But it is necessary for me that the user could get access to the file (.txt, .pdf, .doc and other formats) without any file managers. The file should appear in the system download folder, but it does not appear. The experience with the galleries was the same until the line was added. How to inform the system about a new file in order to access it via the download folder? Perhaps there is another way. Thank you in advance and hope for constructive answers.