I have a NSWindow
in a nib-file owned by a MYWindowController
. The nib-file has a bunch of MYViewController
objects. I wan't to set MYViewController.managedObjectContext
to be the same as MYWindowController.managedObjectContext
but I'm not able to connect those two in Interface Builder.
Is doing this in code my only option? E.g. in MyWindowController
:
- (void)windowDidLoad { // or awakeFromNib
self.myViewController.managedObjectContext = self.managedObjectContext;
}
You can't do that type of connection in Interface Builder.