• 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
Re: Implementing previous, next, first, last controls in Core Data applications
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Implementing previous, next, first, last controls in Core Data applications


  • Subject: Re: Implementing previous, next, first, last controls in Core Data applications
  • From: "I. Savant" <email@hidden>
  • Date: Sun, 12 Jul 2009 09:48:38 -0400

On Jul 12, 2009, at 8:51 AM, Ian Piper wrote:

Can anyone tell me whether there are any plug-ins or examples that show how to implement buttons to move forward and backward through a record set in a Core Data application? I am thinking of having a window that simply presents one record from a collection, with forward, backward, first and last buttons.

This isn't really a "Core Data" question, but rather a bindings question.


Read up on Cocoa Bindings and NSArrayController. All you need to do is modify the selection as desired when these buttons are pressed via - [NSArrayController setSelectionIndex:] or -[NSArrayController setSelectionIndexes:], keeping in mind the array controller's - arrangedObjects (and the count thereof).

If the rest of your detail view is bound to this array controller's selectedObjects.whateverKeys, you're done.

--
I.S.




_______________________________________________

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


  • Follow-Ups:
    • Solved: Implementing previous, next, first, last controls in Core Data applications
      • From: Ian Piper <email@hidden>
References: 
 >Implementing previous, next, first, last controls in Core Data applications (From: Ian Piper <email@hidden>)

  • Prev by Date: Implementing previous, next, first, last controls in Core Data applications
  • Next by Date: Undo without Redo
  • Previous by thread: Implementing previous, next, first, last controls in Core Data applications
  • Next by thread: Solved: Implementing previous, next, first, last controls in Core Data applications
  • Index(es):
    • Date
    • Thread