Is there some kind of a problem with Windows 10, Corona and file writing?
If the file doesn’t exists, the file is written. If the file exists, I’ll get an error message:
attempt to index local 'file' (a nil value)
Code:
local path = system.pathForFile( "gameData.json", system.DocumentsDirectory ) local file = io.open(path, "w") file:write( "Hi!") io.close( file )
Tried also with “w+”
When testing with Mac, everything works.
Corona version 2015.2731 (2015.10.5)
