Re: Manually adding objects to NSArrayController
Re: Manually adding objects to NSArrayController
- Subject: Re: Manually adding objects to NSArrayController
- From: Jenny M <email@hidden>
- Date: Thu, 18 Mar 2010 22:02:00 -0700
Ahhh, thank you, that helped! What I did was add an NSArray property
(though it could've been NSMutableArray), then called setValueForKey,
and bound the ArrayController to that array. And it works great.
Jenny
On Thu, Mar 18, 2010 at 8:26 PM, Scott Anguish <email@hidden> wrote:
> Modify the model, not the controller.
>
> so the model object that holds the array should be called with
>
> mutableArrayForKey:
>
> passing the array variable key.
>
> then mutate the array you get back.. that will be KVO compliant and the changes will be reflected in your controller, and then your view.
>
>
_______________________________________________
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