Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/39.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/swift/19.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone UITabbar还使用额外的UIButton[hell]swift 4更改选项卡_Iphone_Swift_Xcode - Fatal编程技术网

Iphone UITabbar还使用额外的UIButton[hell]swift 4更改选项卡

Iphone UITabbar还使用额外的UIButton[hell]swift 4更改选项卡,iphone,swift,xcode,Iphone,Swift,Xcode,swift 4编程新手需要UIButton中的帮助 约会有两个按钮,一个在tabbar上,另一个是UIButton。 如何编程UIButton以导航到“UIAbbar上的UIView”,而不在导航时消失选项卡栏 我不知道我是否理解您,但如果我是对的,您希望通过触摸UIButton而不是UIAbbarController来访问特定选项卡 解决方案是向按钮添加一个操作,如下所示: 其中x是一个整数,带有选项卡栏中“约会”选项卡的位置。请您花点时间把问题弄清楚,并告诉我们出了什么问题? @IBActi

swift 4编程新手需要UIButton中的帮助

约会有两个按钮,一个在tabbar上,另一个是UIButton。
如何编程UIButton以导航到“UIAbbar上的UIView”,而不在导航时消失选项卡栏

我不知道我是否理解您,但如果我是对的,您希望通过触摸UIButton而不是UIAbbarController来访问特定选项卡

解决方案是向按钮添加一个操作,如下所示:


其中x是一个整数,带有选项卡栏中“约会”选项卡的位置。

请您花点时间把问题弄清楚,并告诉我们出了什么问题?
@IBAction func goToAppointments(sender: AnyObject) {
    tabBarController?.selectedIndex = x
}