iOS 获取相册中图片的名字 url

 __block NSString *imageFileName;
 NSURL *imageURL = [info valueForKey:UIImagePickerControllerReferenceURL];
 ALAssetsLibraryAssetForURLResultBlock resultblock = ^(ALAsset *myasset) {
   ALAssetRepresentation *representation = [myasset defaultRepresentation];
   imageFileName = [representation filename];
}; ALAssetsLibrary
* assetslibrary = [[ALAssetsLibrary alloc] init]; [assetslibrary assetForURL:imageURL resultBlock:resultblock failureBlock:nil];

 

posted @   TigerCui  阅读(1092)  评论(1编辑  收藏  举报
点击右上角即可分享
微信分享提示