Skip to content

Instantly share code, notes, and snippets.

@marchbold
Created October 23, 2018 08:36
Show Gist options
  • Select an option

  • Save marchbold/793a442070cd044f892f8e67b3900609 to your computer and use it in GitHub Desktop.

Select an option

Save marchbold/793a442070cd044f892f8e67b3900609 to your computer and use it in GitHub Desktop.
List files in File.applicationStorage
function listFiles( file:File, prefix:String="" ):void
{
if (file.isDirectory)
{
var files:Array = file.getDirectoryListing();
for each (var f:File in files)
{
listFiles( f, prefix + file.name + "/" );
}
}
else
{
trace( prefix + file.name + " (" + file.nativePath +")" );
}
}
listFiles( File.applicationStorageDirectory );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment