Hi Corona community!
I'm using Media.selectPhoto to open up the photo album, and allowing users to select a picture to import into my Corona SDK app. Is there a way to get the date and time that these pictures were taken?
I've tried to import the picture from the photo album to system.TemporaryDirectory, then using:
local pathOrigin = system.pathForFile( photoData[i].fileName, system.TemporaryDirectory ); local fileAtributes = lfs.attributes(pathOrigin); local dateMod = fileAtributes.modification; local dateTime = os.date("%Y:%m:%d %H:%M:%S", dateMod);
To get the date and time of when the picture was created. This works in the simulator on my computer, but when I tested it on my iPhone it returns the current date and time.
Any help will be much appreciated.
Thank you very much Corona Community!