- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"CustomCell";
CustomCell *cell = (CustomCell *) [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
NSArray *topLevelObjects = [[NSBundle mainBundle] loadNibNamed:@"CustomCell" owner:self options:nil];
for (id currentObject in topLevelObjects){
if ([currentObject isKindOfClass:[UITableViewCell class]]){
cell = (CustomCell *) currentObject;
break;
}
}
}
cell.nameLabel.text = [arrareasdata objectAtIndex:indexPath.row];
cell.designLabel.text = [arrareasdata1 objectAtIndex:indexPath.row];
if(([arrareasdata2 objectAtIndex:indexPath.row].length > 0)
{
cell.emailLabel.text = [arrareasdata2 objectAtIndex:indexPath.row]
}
else
{
cell.emailLabel.text = @"";
}
cell.webLabel.text = [arrareasdata3 objectAtIndex:indexPath.row];
return cell;
}
问问题
842 次