How to create UIImageView with image from a link like this http://img.abc.com/noPhoto4530.gif?
Select New > Project... from Xcode's File menu and choose the Single View App template from the iOS > Application section. Name the project Images and set User Interface to Storyboard. Leave the checkboxes at the bottom unchecked. Tell Xcode where you would like to save the project and click the Create button.
UIImage contains the data for an image. UIImageView is a custom view meant to display the UIImage .
NSURL *url = [NSURL URLWithString:@"http://img.abc.com/noPhoto4530.gif"];
NSData *data = [NSData dataWithContentsOfURL:url];
UIImage *image = [UIImage imageWithData:data];
UIImageView *imageView = [[UIImageView alloc] initWithImage:image];
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With