I'm trying to access an array from a custom UITableViewCell subclass. The array is created in my tableViewController. This is driving me crazy. I access other view controller's objects all the time with ViewController *vcInstance. I actually need to edit the array from my cell subclass, but I can't even NSLog it from my cell view controller. The array logs perfectly in my tableViewController. All I get is null from the cell subclass.
CustomCell.h
@property (retain, nonatomic) SongsViewController *vc;
CustomCell.m
@synthesize vc;
-(IBAction)setStateOfObjects
{
NSMutableArray *array = [[NSMutableArray alloc] initWithArray:vc.parseTrackArray];
NSLog(@"%@", array);
}
I've also simply tried: CustomCell.m
-(IBAction)setStateOfObjects
{
SongsViewController *vc;
NSLog(@"%@", vc.parseTrackArray);
}