Good evening, everyone. I'm trying to do screen transitions programmatically with swift, but I can not. I tried using the navigationController, but it did not work, it always gives a different error. The screens are set up in the same storeboard, I just need to go from screen 1 to screen 2. I tried to use protocols too, but I could not, and I was still more involved. Here's the code I'm trying to use to make the screen switch, this excerpt is in the ViewController:
@IBAction func btnSegue() {
let newTela = TelaDoisViewController(delegate: self)
if let navigation = navigationController {
navigation.pushViewController(newTela, animated: true)
}
}
Thanks in advance for the help.