ios - get file name when using writeImageToSavedPhotosAlbum -


in ios swift application, using writeimagetosavedphotosalbum save uiimage on iphone

let assets : alassetslibrary = alassetslibrary() let imgref : cgimage = myimage!.cgimage let orientation : alassetorientation = alassetorientation(rawvalue: myimage!.imageorientation.rawvalue)! assets.writeimagetosavedphotosalbum(imgref, orientation: orientation, completionblock: nil) 

is there way can saved image filename? or maybe set myself?

thank help

if @ spec of method you're using see completion block aren't using of type alassetslibrarywriteimagecompletionblock, has parameters nsurl *asseturl, nserror *error.

so specify completion block , asset url can derive information.


Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

[C++][SFML 2.2] Strange Performance Issues - Moving Mouse Lowers CPU Usage -

ios - Possible to get UIButton sizeThatFits to work? -