• 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: Removing objects from the array controller but not from the persistent store (Newbie)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Removing objects from the array controller but not from the persistent store (Newbie)


  • Subject: Re: Removing objects from the array controller but not from the persistent store (Newbie)
  • From: Sebastian Morsch <email@hidden>
  • Date: Wed, 2 Nov 2005 00:20:50 +0100


Thanks Marcus!

My mistake was to think of arrangedObjects as the point to manually modify the shown objects (wich only seems to work when subclassing arrangeObjects). Of course, filterPredicate is the most straight forward way to influence the displayed objects.

Cheers, Sebastian




The easiest way is to simply apply a NSPredicate against the array. Depending on how you are accessing the NSArrayController you can set this in Interface Builder or in the code.

Marcus

On Oct 27, 2005, at 2:27 AM, Sebastian Morsch wrote:

Hi!

I have a little core data question:

I'm stuck with the task to implement a Filemaker-style behaviour where a database record can be 'omitted' (made invisible) from the list of shown records. My approach was to try to modify the arrangedObjects that are shown in the table in a NSTableView <bound to> NSArrayController <bound to> NSArrangedObjectContext setup, but it doesn't seem to work that way.

It's obvious how to permanently remove objects from the array controller AND the persistent store, but how can I just 'hide' them? Furthermore, I'd like to be able to show all the 'hidden' objects, i.e. the complement of the currently shown objects, but I have no idea how to achieve this either...

I know it's always a bit silly to think in some other design's ways when developing and I assume, that's where my problem lies. I'd appreciate any help or pointing-me-somewhere very much! Thanks.


Sebastian


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Prev by Date: Re: Changes in CoreData/10.4.3?
  • Next by Date: Control the dirty/clean dot in the red "Close" button
  • Previous by thread: Cocoa Heads Orange County initial meeting
  • Next by thread: Control the dirty/clean dot in the red "Close" button
  • Index(es):
    • Date
    • Thread