• 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
NSTableColumn value binding + keypath over a relationship
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTableColumn value binding + keypath over a relationship


  • Subject: NSTableColumn value binding + keypath over a relationship
  • From: Stamenkovic Florijan <email@hidden>
  • Date: Tue, 29 Sep 2009 17:18:17 -0400

Hi all,

I have been experiencing an error in my app that does not make sense... Here is the situation:

A CoreData app. I have a table and one of it's columns' value bound to an array controller's "arrangedObjects.group.title". The controller contains objects of the Note entity. Note relates to a Group (to-one), and the Group entity has a "title" attribute. Straightforward. Next to the table I have an outline view containing Groups. I have implemented drag and drop so that Notes can be dragged from their table to a different group in the outline view. However, when I have the above described table column present in the table, I get an error after dragging that says:

Cannot remove an observer <NSTableBinder 0x177eb0> for the key path "group.name" from <FSNote 0x1ad240>, most likely because the value for the key "group" has changed without an appropriate KVO notification being sent. Check the KVO-compliance of the FSNote class.

I am quite certain that the Note class is KVO compliant for "group", since I don't do anything to prevent it being, and it's a CoreData entity with @dynamic property generation.

So, I am wondering, am I doing something wrong? It seems a reasonable thing to do, binding a column's value to the "arrangedObjects.relationship.attribute" key path, but maybe that is not allowed?

I have managed to work around this by binding the column to "arrangedObjects.group", and using a custom value transformer. This provides me with exactly the functionality I need, but I am still wondering about the mechanics, and if I am doing something wrong.

Thanks in advance,
F
_______________________________________________

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


  • Follow-Ups:
    • Re: NSTableColumn value binding + keypath over a relationship
      • From: Quincey Morris <email@hidden>
  • Prev by Date: Timer and RunLoop question
  • Next by Date: Re: Timer and RunLoop question
  • Previous by thread: Re: Timer and RunLoop question
  • Next by thread: Re: NSTableColumn value binding + keypath over a relationship
  • Index(es):
    • Date
    • Thread