I get this error when I try to run my app:
2010-04-29 13:49:01.355 MyApp[56123:207] *** Terminating app due to uncaught
exception 'NSUnknownKeyException', reason: '[<MyViewController 0x5112b10>
setValue:forUndefinedKey:]: this class is not key value coding-compliant for
the key toolbar.'
MyViewController used to have an IBOutlet called 'toolbar' that connected to a UIToolbar object in a nib. I decided I no longer needed the toolbar or the nib so I removed them from the project. But Xcode seems to still want to refer to 'toolbar'.
Where might the reference to toolbar be if I no longer use a nib? I can synthesize a dummy 'toolbar' property to appease Xcode, but I want to avoid this kind of ugly hack.
EDIT: Strangely, the exception was not raised when I ran the code on the device rather than the simulator. Also, when I use a trivial nib for MyViewController (which contained no toolbar), the exception went away. I am using git and when I went back to run previous commits of my code from before MyViewController even had a toolbar or a nib, those strangely gave the exception as well. That code used to run fine. I do think this exception has something to do with Xcode and the simulator and some kind of left over state from when I removed the unwanted nib from the project.