Reputation: 6752
I made a folder in my image assets in xcode called weather-large
and I have a file in it that I want to access called clouds.png
So I try to access it this way:
weatherImageView.image = UIImage(contentsOfFile: "weather-large/clouds")
And also tried it this way:
weatherImageView.image = UIImage(named: "weather-large/clouds")
But it both doesn't work while I can access it in the root. What am I doing wrong?
Upvotes: 0
Views: 64
Reputation: 2152
This folders just to group assets. Try:
weatherImageView.image = UIImage(named: "clouds")
Upvotes: 2