Re: Saving Bindings and Editing Font
Re: Saving Bindings and Editing Font
- Subject: Re: Saving Bindings and Editing Font
- From: Ken Thomases <email@hidden>
- Date: Sat, 14 Jun 2008 20:12:35 -0500
On Jun 14, 2008, at 12:16 PM, Gabriel Shahbazian wrote:
1) I have a table view (single column) and a text view hooked up
with bindings to a array controller. How can I get the values
inputed by the user in the column and text view and save them then
load them on launch?
The array controller should have its Content Array binding bound to
your model somehow. The model is where it would get the contents to
show in the table view and, when you add things to the table view,
that's where they would go. It's your model's responsibility to save
and load itself (under direction from a coordinating controller (_not_
the array controller, though)). It can do this in response to a
specific request from the user, for example a button or menu item
sending an action to the coordinating controller; or it can be
implicit, such as when the window closes or application quits. How
you save and load depends on the needs of your model. It can be
something as simple as one of the writeToFile... methods on one of the
common data classes (NSString, NSDictionary, etc.).
Cheers,
Ken
_______________________________________________
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