Re: Using filter predicate on an NSArrayController (simple q)
Re: Using filter predicate on an NSArrayController (simple q)
- Subject: Re: Using filter predicate on an NSArrayController (simple q)
- From: Charilaos Skiadas <email@hidden>
- Date: Tue, 26 Jul 2005 10:33:01 -0500
On Jul 26, 2005, at 8:24 AM, Peter Laurens wrote:
Hi,
I have a very basic setup, just one Entity in my Core Data model,
with one attribute 'name'.
I have created an interface by dragging the entity from the model
view in Xcode to IB.
This has set up the controller etc. for me.
However, I try and set a filter predicate for the
NSArrayController : name == "foo"
but this filter apparently makes no difference whatsoever, in the
tableview bound to the ArrayController I see all the entities
listed as I press the add button, and they all have their default
name which is *not* 'foo'.
Try to edit one of these entries to a name different than foo.
Then they'll go away.
If it didn't work that way, you would never be able to add objects to
your controller.
Is really what you want to control what objects are in the
controller, or what objects show up in the table view. In the latter
case, you probably want to be messing around with the filterPredicate
of the tableView or the tableViewColumn.
I was expecting that only entities with the name 'foo' would be
listed in the tableview. If someone has a moment, perhaps they
could enlighten me as to where I've misunderstood, and why this
isn't working as desired?
Thanks for any help - gratefully received,
- Peter
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40math.uchicago.edu
This email sent to email@hidden
Haris
_______________________________________________
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