Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
- NSString *documentsDirectory = [paths objectAtIndex:0];
- NSString *filePath2 = [NSString stringWithFormat:@"%@/%@.png", documentsDirectory, fileName];
- [UIImagePNGRepresentation(imageToSave) writeToFile:filePath2 atomically:YES];
Add Comment
Please, Sign In to add comment