Re: "No Selection" in Core Data
Re: "No Selection" in Core Data
- Subject: Re: "No Selection" in Core Data
- From: mmalcolm crawford <email@hidden>
- Date: Sat, 25 Jun 2005 10:39:31 -0700
On Jun 25, 2005, at 10:27 AM, J Tichenor wrote:
I'm sure it has something to do with not properly instancing the
Budget Entity when the program launches -- I guess my assumption as
a programmer is that the Budget entity should automatically
instance when the program starts as it must exist
It's not clear what this means. If you haven't set default values in
the model, and you haven't done anything else to set property values,
then property values are nil or 0.
-- but I don't know how to instance the Budget and where --
probably in AppDelegate, right? Maybe in managedObjectContext? I've
tried to find the spot but must admit the autogenerated code
doesn't necessarily make itself apparent...
To set up default values (that are not set in the model), use
awakeFromInsert:
<http://developer.apple.com/documentation/Cocoa/Reference/
CoreData_ObjC/Classes/NSManagedObject.html#//apple_ref/doc/uid/
TP30001171-BBCJFJFC>
<http://developer.apple.com/documentation/Cocoa/Conceptual/
CoreDataUtilityTutorial/06_RunClass/chapter_7_section_2.html>
mmalc
_______________________________________________
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