Hello,
I was trying to read/write files for my android application, everything works out in the simulator I have checked the sandbox and there is the file I am writing and everything, but when I try to do it in the device it does not work I have tried it in two different devices but I always get the same outcome I am using this file:
https://github.com/robmiracle/Simple-Table-Load-Save-Functions-for-Corona-SDK
the loadsave.lua
I have only replaced this line of code to always point to my DocumentsDirectory
local path = system.pathForFile( filename, system.DocumentsDirectory)
In both save and load functions, then in the file where I am trying to read the file I have the following code:
local loadsave = require("loadsave") local myTable myTable = {} function scene:create( event ) myTable = loadsave.loadTable("myTable.json") end
Then in order for me to be able to write it I have the following code, this is called on some button click event:
function writeTable() myTable.musicOn = false--musicOnBtn.isVisible myTable.soundOn = false --SoundOnBtn.isVisible loadsave.saveTable(myTable, "myTable.json") end
Then I have the following config in builds.seetings:
androidPermissions = { "android.permission.INTERNET", "android.permission.WRITE\_INTERNAL\_STORAGE", "android.permission.WRITE\_EXTERNAL\_STORAGE", "android.permission.ACCESS\_FINE\_LOCATION", "android.permission.ACCESS\_COURSE\_LOCATION", },
I read in some other forum that the android.permission.WRITE_INTERNAL_STORAGE may help, I also try removing it but I still get the same outcome.
the devices I am trying on don’t have sd storage just the local one phone or tablet storage, could it be this the problem?, what else can I do on this?
I really don’t know what to do now 
Or is there anyway to set corona to save the data internally?
