Я хочу отображать пользовательские ячейки, но мой код отображает только одну пользовательскую ячейку таблицы сразу. Что я делаю неправильно?Пользовательский UITableViewCell только для рисования одной ячейки
У меня есть UIViewController nib, настроенный с моим UITableView внутри UIView. Также есть UITableViewCell в nib, чей класс - CustomCell (подкласс UITableViewCell). И UITableView, и Cell являются @sythesized IBOutlet @properties.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
NSString *CellIdentifier = @"CellIdentifier";
CustomCell *cell = (CustomCell *)[tableView dequeueReusableCellWithIdentifier:CellIdentifier]; // CustomCell is the class for standardCell
if (cell == nil)
{
cell = standardCell; // standardCell is declared in the header and linked with IB
}
return cell;
}