look at ItemsViewController.m , method didSelectRowAtIndexPath
When the user press a row on the tableview,first thing you do programmatically is to create an instance of the viewController you want to show and pass it the info, in this case the DetailViewController:
then, you created a pointer to the selected item (the item that was in the row pressed) when you did:
//you create an inmutable array here from the BNRITemStore's instance variable "allItems"
NSArray *items = [[BNRItemStore SharedStore] allItems];
//and here you create a new BNRItem pointer that points to the object in the array, this object is the "selected item"
//in other words, you create a pointer to and object that already exists.
BNRItem *selectedItem = [items objectAtIndex:indexPath.row];
Remember you created a property in DetailViewController named Item?..you set that property to the selectedItem pointer in this line
you are playing with pointers, that means when you update the Item properties, you are updating the object who’s being pointed, in this case, the original object in the array, or the object int the selected row.(The object int the position IndexPath.row)
item.itemName = nameField.text;
item.serialNumber = serialNumber.text;
item.valueInDollars = valueField.text.intValue;
item.dateCreated = [dateFormatter dateFromString:dateLabel.text];
that is the reason you have your item’s instance updated in the array but, in order to see the updated data you have to reload the data in the tableView.
Im sorry for my english since spanish is my native language.
Let me know if you undertand this.