2
我有一個UITableView,我想在UITableViewController中編輯。這段代碼來自我調用編輯tableView的方法。UITableView NSInternalInconsistencyException錯誤拋出;一個單元格的兩個動畫
[self.tableView beginUpdates];
[self.tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject: path] withRowAnimation:UITableViewRowAnimationNone];
[self.tableView insertRowsAtIndexPaths:[NSArray arrayWithObject: path] withRowAnimation:UITableViewRowAnimationNone];
NSMutableArray *things = [[self.fetchedResultsController fetchedObjects] mutableCopy];
self.storedCell = [things objectAtIndex: path.row];
[things removeObjectAtIndex: path.row];
for (int i = 0; i < [things count]; i++) {
Task *mo = (Task *)[things objectAtIndex: i];
[mo setValue:[NSNumber numberWithInt: i] forKey:@"displayOrder"];
}
[things release]; things = nil;
self.newPath = path;
[self.managedObjectContext save: nil];
[self.tableView endUpdates];
,這是拋出的錯誤:
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Attempt to create two animations for cell'
任何想法對我做了什麼錯?
這是什麼運氣? – lnafziger 2012-04-13 03:30:50
是的重新調用工作,感謝您的幫助! – geenen124 2012-04-13 19:30:53