filesystems - Loop through all the files in a directory with Corona and Lua -
is possible in corona sdk list of files in directory? have variable resourcedir = system.resourcedirectory, how loop through files in resourcedir?
this functionality has been added corona including luafilesystem module:
local lfs = require "lfs" local doc_path = system.pathforfile( "", system.documentsdirectory ) file in lfs.dir(doc_path) -- file current file or directory name print( "found file: " .. file ) end more info: http://blog.anscamobile.com/2012/05/luafilesystem-lfs-tutorial/
Comments
Post a Comment