Need help on iOS Swift error.

+1 Shrey Shah · January 24, 2016

mport UIKit

class ViewController: UIViewController
{
    
    
    @IBOutlet weak var emailip: UITextField!
    @IBOutlet weak var passwordip: UITextField!
    
    
    @IBAction func loginButton(sender: UIButton)
    {
        self.emailip.resignFirstResponder()
        self.passwordip.resignFirstResponder()
        
    }
    
    override func touchesBegan(touches: NSSet, withEvent event: UIEvent)
    {
        self.view.endEditing(true)
    
    }
        
}

i am getting the following error on override statement "Method doesnt override any method from its superclass"

Post a Reply

Replies

Oldest  Newest  Rating
0 Koushik Karmakar · March 23, 2016
did you define the viewDidLoad() method ??
  • 1

iOS Development / Swift

129,919 followers
About

This forum is for questions, comments, and general discussion about iOS Development and Swift.

Links
Moderators
Bucky Roberts Administrator