Реализован UITableView с пользовательским UITableViewCell с кодом ниже
@interface ProfileSaveViewController : UITableViewController
{
UITableViewCell *cell0;
UITableViewCell *cell1;
UITableViewCell *cell2;
UILabel *cell2Label;
}
@property (nonatomic, retain) IBOutlet UITableViewCell *cell0;
@property (nonatomic, retain) IBOutlet UITableViewCell *cell1;
@property (nonatomic, retain) IBOutlet UITableViewCell *cell2;
@property (nonatomic, retain) IBOutlet UILabel *cell2Label;
@end
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath: (NSIndexPath*)indexPath
{
if([indexPath row] == 0) return cell0;
if([indexPath row] == 1) return cell1;
if([indexPath row] == 2) return cell2;
return nil;
}
при запуске приложения пришло следующее сообщение.
* Ошибка подтверждения в - [UITableView _createPreparedCellForGlobalRow: withIndexPath:],/SourceCache/UIKit_Sim/UIKit-1912.3/UITableView.m:6072 2012-03-01 11: 11: 31.984 TestSplitView [765: f803] * Завершение работы приложения из-за невыполненного исключения «NSInternalInconsistencyException», причина: «UITableView dataSource must»вернуть ячейку из tableView: cellForRowAtIndexPath: '