I am new to swift programming and I have a Tabbed application with 2 UITabBar items , I want that when user taping the second tab, application set the selected tab index to 0 and move user to the first tab. I tried this code in my SecondViewController.swift's viewDidLoad
:
self.tabBarController?.selectedIndex = 0
but it doesn't work.