Hi Guys I am creating a iOS(Universal) application. My problem is that in my application there is a UITableView that works fine if the application doesn't goes to background(By pressing home button or by clicking a URL link).
If the application goes into the background, when it gets active, reloading a cell or the whole table view crashes the whole application.
Any Solution???
Is removing the dequeueReusableCellWithIdentifier: will make some difference??
The code is :
- (UITableViewCell *)tableView:(UITableView *)tableView1 cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
static NSString *identifier = @"Cell";
UITableViewCell *cell = [tableView1 dequeueReusableCellWithIdentifier:identifier];
if(cell == nil){
cell = [[UITableViewCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:identifier];
}
Animation *animation = [animationArray objectAtIndex:indexPath.row];
cell.textLabel.text = animation.title;
if(animation.isAnimationEnabled){
cell.imageView.image = OnImage;
}else {
cell.imageView.image = OffImage;
}
return cell;
}