Reputation: 13
This is the sequence of steps I have taken:
I had this problem also with sqlite, and I didn't fix it. No, I am also stacked with CoreData.
-(IBAction)save:(id)sender
{
[passwords setValue:nametxt.text forKey:@"name"];
[passwords setValue:usernametxt.text forKey:@"username"];
}
-(void) viewWillAppear:(BOOL)animated
{
self.title = passwords.name;
nametxt.text = passwords.name;
usernametxt.text = passwords.username;
}
Upvotes: 0
Views: 172
Reputation: 26937
You need to call save
method of your NSManagedObjectContext
.
NSError *error = nil;
[managedObjectContext save:&error];
if (error) {
//inform user
}
Upvotes: 2