Hi,
Im using os.remove to delete files from system.DocumentsDirectory in my project. Its an image file
local destDir = system.DocumentsDirectory
local results, reason = os.remove( system.pathForFile(name, destDir )
print(reason)
this is the code name is name of the image file . This does not work and gives me the reason as “Permission denied”
but when i change the name and give “img.jpg” (in the option it deletes the file .
I think the reason may be that the line is taken from a file using
for line in title_file:lines() do
name=line
end
there is only one line in the file i made sure of that
please help
Thank you
[import]uid: 115284 topic_id: 26497 reply_id: 326497[/import]