Mac OS X's Preferences System (and More!)
Subject:   Sorting?
Date:   2001-09-14 22:20:55
From:   n9yty

I've been trying to figure out (with no luck) how to get the tableView to sort....

I looked around and found a reference in setDoubleAction:(SEL) to set a selector used when a column header is double clicked... But how do I tie that to my code?

Further, I see clickedColumn in tableView, but it returns an index... Since you can re-arrange the columns, how do you know which one is which at runtime? I thought about something like using tableColumns to get the columns, then objectAtIndex:colnum to get the column clicked in, and finally the identifier method of this to get the column name.

Is this the wrong path? Any insight, please? :-)

Thanks for a great series of articles. I gave up most of my C programming back when I switched from my Amiga (Intuition was a nice environ for it's time, IMHO) to Windows (VisualBasic, but let's not go there...), and since moving to the Mac I've never gotten into programming, but Cocoa and MacOS X are really intriguing me... Most of my day-to-day work is in Perl/Shell/SQL/C for various Unix "back-end" things.

1 to 1 of 1
  1. Sorting?
    2001-09-15 06:08:57  n9yty [View]

    • Sorting - Sorting it out...
      2001-09-15 20:21:36  n9yty [View]

      • HELP!!!
        2002-02-08 02:40:53  stupidfish23 [View]

1 to 1 of 1