Tab Bar 앱에서 스토리 보드가있는 RSS 리더 드릴 다운 테이블을 개발하려고합니다. 내 RootTableViewController를 파싱 된 XML로 채 웠습니다. 이제는 내 RootTableViewController의 각 행을 가리키고 선택된 셀의 데이터를 다른 DetailTableViewController로 전달하는 방법에 대한 문제가 발생했습니다.UITableView는 스토리 보드를 사용하여 UITableView 드릴 다운을 수행합니다.
이 내 코드의 일부는 XML을 구문 분석하고 RootTableViewController 채울 수 있습니다 :
스토리 보드에서- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
return [stories count];
}
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"AdvCurrentCelly";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
}
int storyIndex = [indexPath indexAtPosition: [indexPath length] - 1];
NSString *description = [[stories objectAtIndex: storyIndex] objectForKey: @"description"];
NSString *title = [[stories objectAtIndex: storyIndex] objectForKey: @"title"];
//This populates the prototype cell 'AdvCurrentCelly'
cell.textLabel.text = title;
//cell.textLabel.text = date;
cell.detailTextLabel.text = description
return cell;
}
의 DetailTableViewController에 RootTableViewContoller 세포에서 SEGUE의 이름 ShowADVDetail
도움말이 훨씬입니다 감사합니다