Re: filtering the values in an NSTableColumn
Re: filtering the values in an NSTableColumn
- Subject: Re: filtering the values in an NSTableColumn
- From: Koen van der Drift <email@hidden>
- Date: Thu, 09 Aug 2012 08:58:40 -0400
Ok, doing some more thinking, but am not at my Mac now to test it.
Maybe I should use a predicate, something like this:
valueFilter = [NSPredicate predicateWithFormat:@"%@ < value < %@",
self.minimumValue, self.maximumValue];
[myArrayController setFilterPredicate: valueFilter];
As I said I'm not able to test it until later today, but I wanted to
throw it out to see if there are any comments/suggestions. The two
values are bound to the textfields, so hopefully this will update the
display automagically when the user changes the value(s).
- Koen.
On Wed, Aug 8, 2012 at 8:17 PM, Koen van der Drift
<email@hidden> wrote:
> I'd like to filter the values in a table column based on values entered in two NSTextFields by the user (min and max).
>
> I tried to bind the Min Value and Max Value of the column to the NSTextField float value property, but that didn't change anything. I also created a min and max property in my controller and bind to that, but again, no filtering occurs.
>
> How can I do this?
>
> OS X, cell based table.
>
> Thanks,
>
> - Koen.
_______________________________________________
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