I don't get what I am doing wrong, I am trying to perform a push segue by an identifier so that I can move to other view-controller when an IF condition gets TRUE
the segue is always performed either I add this method : override func prepareForSegue()
     @IBAction func btnClicked(sender: AnyObject) {
    if(n.isEqualToString("mpc01") && p.isEqualToString("mpc01"))
               {
    self.performSegueWithIdentifier("login_to_dashboard", sender: nil)
               }
               else{
                println("no data retrieved")
                }
    }
 override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
        if segue.identifier == "login_to_dashboard" {
           // let secondViewController = segue.destinationViewController as VC_dashboard
            println("performed segue")
        }
        else{
        println("recieved other command")
        }
    }
my ViewController storyboard ID : SID_login
my SecondViewController storyboard ID : SID_dashboard
my Push Segue ID : login_to_dashboard
I want to perform segue by its ID only , not directly
 
     
     
     
    