編集:あなたはオブジェクト参照がどのように機能するかを完全には理解していません。配列、またはそれを「保持」している他のオブジェクトからオブジェクトを要求する場合、新しいオブジェクトは作成されません。したがって、「前のオブジェクト」と「更新されたオブジェクト」で終わることはありません。このことを考慮:
NSMutableDictionary *dict = [array objectAtIndex:index];
[dict setObject:@"Hello" forKey:@"Status"];
//You don't need to add *dict back to the array in place of the "old" one
//because you have been only modifying one object in the first place
[array replaceObjectAtIndex:index withObject:dict]; //this doesn't do anything
それを考慮して...
あなたがこれについて行っている方法は逆です。配列のUITableVieCellサブクラスにプロパティを作成します
interface CustomCell : UITableViewCell
@property (nonatomic,retain) NSMutableArray *vcArray;
@end
#import CustomCell.h
@implementation CustomCell
@synthesize vcArray;
-(IBAction)setStateOfObjects {
NSMutableDictionary *dictionary = [parseTrackArrayToBeModified objectAtIndex:currentIndex];
[dictionary setObject:[NSNumber numberWithBool:YES] forKey:@"sliderEnabled"];
//THIS LINE IS REDUNDANT
//[parseTrackArrayToBeModified replaceObjectAtIndex:currentIndex withObject:dictionary];
//END REDUNDANT LINE
}
//in your ViewController's delegate method to create the cell
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
//assume previous code has CustomCell created and stored in variable
CustomCell *cell;
cell.vcArray = self.parseTrackArray;
return cell;
}