Set different external storage path for

I would like to save the photos in the private folder of the application (android/data/com.companyname...) on the SD card and not on emulated/0/Android/data/... Is it possible to change this parameter or do I have to create my own custom camera?

I get the path from Context.GetExternalFilesDirs list


Best Answer


  • AlessandroAlbiAlessandroAlbi Member ✭✭

    Thank you,
    clear and file.copy/file.move is a good solution for me.
    But at this point I have another question... WhatsApp , Telegam and other app that use camera are able to save the shots in SD/DCIM/ why do they succeed and doesn't evenSaveToAlbum = true is set? I've to create my own camera logic?

  • readnreadn Member ✭✭

    I tried a text file Copy from Phone to SD. It raised an unauthorized Access Exception on SD.

  • readnreadn Member ✭✭
    edited February 11

    I wrote "I tried a text file Copy from Phone to SD. It raised an unauthorized Access Exception on SD".
    In fact, there is no error if the destination directory is a private directory of the SD card.
    For example the private picture directory path on the SD card of my Galaxy phone is /storage/0123-4567/Android/data/Phoneword.Phoneword/files/Pictures given by GetExternalFilesDirs(Android.OS.Environment.DirectoryPictures)[1].AbsolutePath..
    "Phoneword" is the name of the application, [1] is the index of SD memory.

    Only private files or directories are writable on SD card. All others files are read only.
    I beg your pardon for this mistake.

  • AlessandroAlbiAlessandroAlbi Member ✭✭

    Sorry I had not seen your answer of February 8, yes I also ran into the problem of being able to write only in the app's private folder on the SD and not in the root. For this reason I was wondering why other apps manage to have access, for example, to the DCIM folder on the SD

Sign In or Register to comment.