iOS – Passing variable to view controller

When a view controller is being initialized, inside the initWithNibName method, the views that reside in the view controller aren’t yet initialized and you can’t set their properties yet. Do whatever you need that is view based in the “viewDidLoad” method.

Leave a Comment