• 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
Saving NSObjectController info
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Saving NSObjectController info


  • Subject: Saving NSObjectController info
  • From: <email@hidden>
  • Date: Tue, 15 Feb 2005 9:30:26 +0000

Now, I'm sure this has been asked before, but before you all lay into me, I have done an exhaustive internet and mailing list search, including Malcom's site, to this and I'm still stumped.

I have a very basic doc-based application.  I want to implement an NSObjectController to manage the model object it contains.  Nothing fancy here, just a single object and nothing more.

I know how to set this all up.  I've done the examples (CurrencyConverter with Bindings and all of that), that's not the issue.  What I want to be able to do is give the user the ability to save the object information to disk in the form of an archived file.  Now, my model object is already set up for this (NSCoding, yadda yadda), as well as MyDocument being able to save and retrieve the info from disk.

But where do I get the info from?  Through the user interface, the values in each text field are stored in the model object instance that NSObjectController creates, but how do I programmatically get at that object instance so I can archive it and save it do disk, and subsequently unarchive it to open a file?  Just some basic stuff, but I can find nothing.  I did find one forum where this very question was asked (it was a MacAddict forum I believe) from 2003, but there was never an answer given.  Any help you can give will be greatly appreciated.

James

 _______________________________________________
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

  • Prev by Date: NSTableView question
  • Next by Date: Saving NSObjectController info
  • Previous by thread: Re: NSTableView question
  • Next by thread: Saving NSObjectController info
  • Index(es):
    • Date
    • Thread