Question: My Xcode project has a navigation controller, and the main viewcontroller has a UIButton that pushes a new view. How to assign my "SecondViewController" as the view controller class for the second view?

Answer: 
In your interface builder > open the inspector on the right, select the Identity Inspector (3rd option), and under custom class, enter the name of your class.

![enter image description here](https://i.stack.imgur.com/DThmH.png)
Go to interface builder, see the property inspector top right (i cant remember the rght name), select your view controller, 2nd tab i believe, there's you class name box.