I am trying to get picture taken date while choosing picture from Photo Library in iPhone. I am using below code to do the same.
NSDictionary* fileAttribs = [[NSFileManager defaultManager] attributesOfItemAtPath:path error:nil];
NSDate *result = [fileAttribs fileCreationDate]; //or fileModificationDate
But it is showing current date and time.
Is there any way to get picture taken date while choosing picture from Photo library.
ALAssetsLibrary is deprecated, so with PHAsset:
Then:
You can do it checking the metadata of the picture with ALAsset
Look for the key
ALAssetPropertyDate
EDIT, complete code: