Lord Vermillion
Lord Vermillion

Reputation: 5414

Swift 2.0 use of undeclared type UIColor

Why can't i use UIColor in Swift 2.0?

Makes no sense.

enter image description here

Upvotes: 15

Views: 8643

Answers (2)

Markus
Markus

Reputation: 777

You have to import UIKit to use UIColor.

Upvotes: 8

Dharmesh Kheni
Dharmesh Kheni

Reputation: 71854

Just add import UIKit at the top and it will work fine.

Upvotes: 60

Related Questions