• 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
Stopping a TableView being sortable
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Stopping a TableView being sortable


  • Subject: Stopping a TableView being sortable
  • From: Matt Gough <email@hidden>
  • Date: Wed, 21 Dec 2005 11:53:41 +0000

I am sure I must have overlooked something here, but how do I create a TableView that can't be sorted?

My table has one column with a visible header and is bound to an an ArrayController that returns an array of strings which I always want displayed in the order they are in the array.

At startup, my table appears unsorted

Once I click on the column header, the following gets logged to the console, the header turns blue and the sorting arrow appears (but the items themselves do not change position)

2005-12-21 11:22:23.887 SmartSearchTester[9008] Error setting value for key path sortDescriptors of object <NSArrayController: 0x38ec00> [object class: NSString, number of selected objects: 1] (from bound object <NSTableView: 0x383d40>): [<NSConstantString 0xe274> valueForUndefinedKey:]: this class is not key value coding-compliant for the key .

I have been looking for an 'Is Sortable' checkbox in Interface Builder to no avail and have tried setting the Table's sortDescriptors to an empty array and the column's SortDescriptorPrototype to nil.

What am I missing?

Matt Gough
Softchaos Ltd.
_______________________________________________
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
  • Follow-Ups:
    • Re: Stopping a TableView being sortable
      • From: mmalcolm crawford <email@hidden>
  • Prev by Date: Re: Implementing a scrollable icon-table
  • Next by Date: Re: Stopping a TableView being sortable
  • Previous by thread: Re: Testing universal binary one the cheap
  • Next by thread: Re: Stopping a TableView being sortable
  • Index(es):
    • Date
    • Thread