I have an NSArrayController that is connected to my Entity in Core Data. I have an IBOutlet attached to the NSArrayController so that I can add objects from my Delegate.
I am trying to add an Object to the NSArrayController with a some presets. So far I have found out how to add an object using.
[cards add:sender];
This works but it adds a blank object. When I exit out of the app it saves this object to the Entity, so that when I hope it again it is still there.
But I also found a way to create a new object with presets, but it doesn't save if like the last method did.
NSDictionary *addedObject = [NSDictionary dictionary];
addedObject = [NSDictionary dictionaryWithObjectsAndKeys:@"TITLE", @"title",
@"CONTENT", @"content", nil];
[cards addObject:addedObject];
Are there any other ways to create a new object with presets but make it so it saves as well? I am new to Core Data, so I'm not 100% on all of this. Maybe there is a way to create a pointer to the actual Entity and edit it from there?