Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Just add <code>nameLabel</code> in cell same like <code>labelName</code> see the code bellow..</p> <pre><code>if(tableView == self.tableView) { UILabel *nameLabel = (UILabel *)[cell viewWithTag:201]; nameLabel.text = [self.allItems objectAtIndex:indexPath.row]; [cell addSubview:nameLabel]; ///YOU ARE Not add This Lable so Add this lable also } else if(tableView == self.searchDisplayController.searchResultsTableView) { UILabel *labelName = [ [UILabel alloc ] initWithFrame:CGRectMake(50, 0.0, 150.0, 43.0) ]; labelName.text = [self.searchResults objectAtIndex:indexPath.row]; [cell addSubview:labelName]; } </code></pre> <p>here in your <code>didSelectRowAtIndexPath</code> method u just take value of <code>self.allItems</code> array instead of <code>self.searchResults</code> array WHEN you are in <code>searchResultTableView</code></p> <p>try this code </p> <pre><code>- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;{ if(tableView == self.tableView) { NSLog("\n Normal Table View Selected cell ==&gt; %@",[self.allItems objectAtIndex:indexPath.row]); } else if(tableView == self.searchDisplayController.searchResultsTableView) { NSLog("\n Search TableView Selected cell ==&gt; %@",[self.searchResults objectAtIndex:indexPath.row];); } } </code></pre> <p>and also in <code>numberOfRowsInSection</code> method set row like bellow...</p> <pre><code>-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ if(tableView == self.tableView) { return [self.allItems count]; } else{ return [self.searchResults count]; } } </code></pre> <p>i hope this help you...</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload