…oh man the forum just ate my original post :( Let’s try again
The issue seems to be with what directory this brings back:
[lua]
local path = system.pathForFile("", system.ResourceDirectory)
print (“Path:”,path)
[/lua]
On my Mac, I get: /Applications/CoronaSDK/Corona Simulator.app/Contents/Resources/CoronaResources.bundle/Contents/Resources
I was expecting it to give me my project folder, or the sandbox, but it gave me this ‘virtual space’ inside the corona simulator instead. There were widget files inside, along with the folder that I created with my earlier test, which explains why i was able to pull that directory listing without getting an error.
I was able to get a folder listing by specifying the full folder path to the simulator’s sandbox on my mac:
[lua]
new_folder_path = “/Users/raymonddelia/Library/Application Support/Corona Simulator/folder access-59F5788A4F8488A6F0E9C61EA944F2C7/myFolder”
[/lua]
I had to copy in the ‘myFolder’ contents to the sandbox folder , since the simulator did not do it automatically.
Since that worked, I tried pointing to my project file:
[lua]
new_folder_path = “/Users/raymonddelia/Documents/Corona Projects/folder access/myFolder”
[/lua]
It’s pretty odd that specifying the folder/file seems to actually point to the project’s structure, like in your example.
It looks like the big show stopper is android, where we don’t get a path for the directory at all.