On Wed, Apr 8, 2009 at 4:05 PM, Jon C. Munson II <jmun...@his.com> wrote:
> I have a combo-box whose content needs to be the aggregated values of the > attribute it is bound to. Ideally, I'd like this sorted. > > Binding content/content values to @distinctUnionOfObjets.attribute yields an > unordered list - not quite so friendly. Yes, this is a FAQ. Since Core Data deals in sets (NSSet / NSMutableSet - by definition, unordered), you have to sort the list by some attribute. Either an alphanumeric sort or if you want to allow designation of an arbitrary order, you'll want to create a "sortOrder" attribute. > So, I've created a relevant method to fetch & load an ordered list. > > Now, I'd like to monitor that attribute for any change so I can re-load my > list. What kind of attribute is it? It should be as easy as setting the desired sort descriptors (see NSSortDescriptor and associated companion guide(s)) on the array controller that's providing your list. -- I.S. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com