• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Core Data, NSTableView, Bindings, in code update problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Data, NSTableView, Bindings, in code update problem


  • Subject: Re: Core Data, NSTableView, Bindings, in code update problem
  • From: Jerry Krinock <email@hidden>
  • Date: Wed, 9 Feb 2011 16:15:37 -0800

On 2011 Feb 09, at 15:22, Darren Wheatley wrote:

> I have some code that does this update [update the values in the data inspector panel], but the changes are not mirrored in the main NSTableView, and are also not saved to the Core Data store.

I think that what you call a "data inspector" is more commonly referred to as a "detail view".

> I'm assuming that this is a KVO-type issue, in that the code update of the fields in the data inspector is not notifying the appropriate objects?

Your code should update the *data model*, not the field values in the detail view.  Provided that this is done using the standard (KVO-compliant) accessors,  Cocoa bindings will then propagate these changes in your data model to your two views (detail view and table view).

Maybe it could be make to work the way you're doing it, but it's much easier to follow the beaten path as I have described.

_______________________________________________

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

References: 
 >Core Data, NSTableView, Bindings, in code update problem (From: Darren Wheatley <email@hidden>)

  • Prev by Date: Core Data, NSTableView, Bindings, in code update problem
  • Next by Date: Re: Initializing NSError **, again Re: CoreData Migration Problems
  • Previous by thread: Core Data, NSTableView, Bindings, in code update problem
  • Next by thread: NSSearchfield help
  • Index(es):
    • Date
    • Thread