J'ai UITableView
dans UIViewController
et j'ai connecté par le biais de sortie et delegete et source de données sont affectés à soi-même. numberOfSectionsInTableView
et numberOfRowsInSection
OBTIENNENT appelé j'ai essayé en utilisant NSLog
mais cellForRowAtIndexPath
ne reçoit pas appeler mon code ressemble-tableView: cellForRowAtIndexPath: ne se fait pas appeler
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
NSLog(@" cellForRowAtIndexPath ");
static NSString *CellIdentifier = @"CurrencyCell";
CurrencyCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[CurrencyCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:CellIdentifier] ;
}
new *Obj = [appdelegate.array objectAtIndex:indexPath.row];
cell.CurNameLabel.text = Obj.C_Name;
cell.textLabel.text = @"sdfnhsdfndsio;";
NSLog(@"C_Name %@", Obj.C_Name);
return cell;
}
quelqu'un peut-il tel wer que je fais Merci d'erreur à l'avance
avez-vous connecté les délégués et la source de données aussi dans IB –
y ai-je connecté –
Quelles sont les valeurs que vous renvoyez dans 'numberOfSectionsInTableView' et' numberOfRowsInSection'? – mttrb