同じクラスに 2 つのテーブルがあり、各テーブルに異なるデータが含まれている必要がありますが、デリゲートに問題があります... 各テーブルに個別のデリゲートを含めるにはどうすればよいですか? ありがとう、私の英語でごめんなさい。
-(NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{
return 1; }
-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
return [dataTable1 count];
}
-(UITableViewCell *)tableView:(UITableView *)aTableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
CeldaFamilia *cell = (CeldaFamilia *)[aTableView dequeueReusableCellWithIdentifier:@"CeldaFamilia"];
if (!cell) {
NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"CeldaFamilia" owner:self options:nil];
cell = [nib objectAtIndex:0];
}
cell.propTextFamilia.text =[dataTable1 objectAtIndex:indexPath.row];
return cell;
}