Hye guys,
i am having trouble with my search. It displays the search results correctly, but when you click on item A in the results, it opens up Item c's description.
It seems like the problem is here:
Code:
-(void) tableView:(UITableView *)tableView
didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
NSLog(@">>> Entering %s <<<", __PRETTY_FUNCTION__);
FSDAppDelegate *delegate = (FSDAppDelegate *)[[UIApplication sharedApplication] delegate];
DetailViewController *detailVC = [[DetailViewController alloc] initWithNibName:@"DetailViewController" bundle:nil];
detailVC.banner = [bannerImages objectAtIndex:indexPath.row];
detailVC.description = [descArray objectAtIndex:indexPath.row];
detailVC.title = [contentsList objectAtIndex:indexPath.row];
self.childController = detailVC;
[delegate.navigationController pushViewController:childController animated:YES];
[detailVC release];
[tableView deselectRowAtIndexPath:indexPath animated:YES];
NSLog(@"<<< Leaving %s >>>", __PRETTY_FUNCTION__);
}
I am not sure, i am pulling my description from a plist. It seems like detailVC.title = [contentsList objectAtIndex:IndexPath.row]; needs to also be able to use the descArray? ideas?
Thanks in advance!