Binding to selection of NSArrayController manually
Binding to selection of NSArrayController manually
- Subject: Binding to selection of NSArrayController manually
- From: Ivy Feraco <email@hidden>
- Date: Fri, 13 Mar 2009 11:42:24 -0400
Hello everybody
Bindings problem:
I have an NSArrayController subclass and an NSPopUpButton subclass.
I am trying to bind the NSPopUpButton's selected object to the
selection of my array controller.
I have to do this manually for reasons I won't get into here.
But when I do this (self is myPopUpButton)
[self bind:@"selectedObject" toObject:ArrayController
withKeyPath:@"selection" options:nil];
I get the error that my array controller is not KVC for the key path
selection.
"selection" is definitely a controller key option in Interface
Builder, is it possible that this doesn't work programmatically?
Has anyone else run into this problem???
I want to bind to the selected object, not the index... so it seems my
only option here is selectedObjects, which I will have to pass an
array of one object to.
Ivy Feraco
UI Developer
email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden