Я получаю сообщение об ошибке в приведенном ниже коде. ..L1name
, L1email
, L1code
- это названия объектов для массива nameData
, nameEmail
, nameCode
.как разрешить error- свойство 'text' не найдено на 'object' типа UITableView в ios
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
static NSString *simpleTableIdentifier = @"SimpleTableCell";
SimpleList1 *cell = (SimpleList1 *)[tableView dequeueReusableCellWithIdentifier:simpleTableIdentifier];
if (cell == nil) {
NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"SimpleTableCell" owner:self options:nil];
cell = [nib objectAtIndex:0];
}
cell.L1name.text = [nameData objectAtIndex:indexPath.row];
cell.L1email.text = [nameEmail objectAtIndex:indexPath.row];
cell.L1code.text = [nameCode objectAtIndex:indexPath.row];
return cell;
}
надстройку еще немного кода. –
Является ли сообщение об ошибке «UITableViewCell»? – Wain
правильно добавил метку для настройки в tablecell – codercat