Here is my code that doesn't work. At first I tried to load an image from a file, now I use a named image:
- (void)viewDidLoad
{
[super viewDidLoad];
UIImage *imageYouWantToPass = [UIImage imageNamed:@"bl_5_00"];
self.mainImage.image = imageYouWantToPass;
}
If I put the image in the Images.xcassets folder, should the above code work? In other words, if the image does not appear, is it due to an error elsewhere in my code?
source
share