Re: Programmatically sort NSTableView
Re: Programmatically sort NSTableView
- Subject: Re: Programmatically sort NSTableView
- From: Brian Amerige <email@hidden>
- Date: Wed, 08 Nov 2006 07:57:35 -0500
Quite simply:
NSArray *newDescriptors = [YourTable sortDescriptors];
[YourArrayWhichProvidesDataToYourTable
sortUsingDescriptors:newDescriptors];
[YourTable reloadData];
:-)
On Nov 6, 2006, at 11:12 PM, Trygve Inda wrote:
I have an NSTableView with 3 columns. When I click on a header, it
sorts on
that column automatically (and reverse order if I click again). How
can I do
this programmatically? (ie cause my table to initially appear with
a column
already set)?
Thanks,
Trygve
_______________________________________________
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
_______________________________________________
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