带有 segue 的 Xcode 6.1 按钮 [英] Xcode 6.1 button with segue

查看:22
本文介绍了带有 segue 的 Xcode 6.1 按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用由登录按钮激活的 segue 进行视图更改.但是我在 Xcode 6.1 中找不到 performSeguewithIdentifier 函数.这样做的正确方法是什么?

I am trying to do view change with segue which activated by login button. But I cannot find performSeguewithIdentifier function in Xcode 6.1. What is the proper way to do that ?

这是我的场景

用户输入邮件和密码,然后点击登录按钮 (1)应用程序检查用户信息是否正确,然后将激活下一个视图(2)

User enters mail and password then clicks login button (1) Application checks user information if it is correct, then next view will be activated (2)

我已经做了应用服务器连接和信息检查,所以我需要一种在检查信息后打开新视图的方法.

I already did application server connection and information checking so I need a way of opening new view after checking information.

推荐答案

示例如下:

self.performSegueWithIdentifier("push", sender: self)

override func prepareForSegue(segue: UIStoryboardSegue!, sender: AnyObject!) {
if segue.identifier == "push" {

}

也许这可以帮到你.

这篇关于带有 segue 的 Xcode 6.1 按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆