It seems like since recent times, view controllers automatically load a nib file with the exact name if one exists.
I can simply initialize a view controller like
[[[ViewController alloc] init] autorelease]
and then when pushing it onto a navigation controller or so, the nib gets loaded without me ever doing anything.
This works in my app except for one view controller and I fail to figure out why. All view controllers that do load their nibs automatically have probably been created in Xcode 4, while the only one where it doesn’t work was propably created back in Xcode 3. Is there a hidden switch somewhere? I coulud not find anything in the file settings of the nib, the nib itself and nothing in the source code of the view controllers that could explain it.
iOS has a case-sensitive filesystem, so make sure the case matches.
Double-check that the nib is enabled for the target you are building.
Check you don’t have a
loadViewmethod.Check the default handling for the
nibNameproperty.