almost 11 years ago
Hi all, If you want to add two different xibs in a tableView you can check out the code here.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { if (tableView==carTable) { ReviewModel *reviewObject=[dictArray objectAtIndex:indexPath.row]; static NSString *CellIdentifier = @"ReviewCell"; cell = (ReviewCell *)[tableView dequeueReusableCellWithIdentifier:CellIdentifier]; cell = nil; BOOL noImage = reviewObject.photo.length == 0; if (cell == nil) { NSArray *nib = [[NSBundle mainBundle]loadNibNamed:noImage?@"SearchCellWithoutImage":@"ReviewCell" owner:self options:nil]; cell = [nib objectAtIndex:0]; } if (!noImage) { // code for one xib (function calls) }else { // code for other xib(function calls) } return cell; } }
Starting with Chrome version 45, NPAPI is no longer supported for Google Chrome. For more information, see Chrome and NPAPI (blog.chromium.org).
Firefox and Microsoft Internet Explorer are recommended browsers for websites using java applets.
Chrome Version Support
Are you sure, you want to delete this comment?
Sign up using
0 Comment(s)