I have 1 view controller that holds a property that I want to pass to another view controller
View controller A:
@interface StackTableViewController () <NSFetchedResultsControllerDelegate>
@property (nonatomic, strong) NSFetchedResultsController *fetchedResultController;
@property (nonatomic, strong) Target *current;
@end
@implementation StackTableViewController
- (void)viewDidLoad {
[super viewDidLoad];
[self.fetchedResultController performFetch:nil];
NSIndexPath *indexPath = [NSIndexPath indexPathForItem:0 inSection:0];
Target *record = [self.fetchedResultController objectAtIndexPath:indexPath];
self.current = record;
}
Now I want another view controller to be able to get the target property attribute values.. Like it's NSString body attribute.
How this should be done?
should I this view controller property in the other view controller(view controller B)? how do I do this?
thanks