我有一个应用程序(导航控制器),其中第二个控制器是一个表视图控制器.我能够通过segue发送我所需的数据,但无法以编程方式更新tableview中的条目. 我是IOS的新手. 这是我的头文件 #impor
          我是IOS的新手.
这是我的头文件
#import <UIKit/UIKit.h> @interface HCIResultListViewController : UITableViewController @property (strong,nonatomic) NSMutableDictionary *resultList; @property (strong, nonatomic) IBOutlet UITableView *tableListView; @end
这是我的实现文件.
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
    #warning Potentially incomplete method implementation.
    // Return the number of sections.
    return 0;
}
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
#warning Incomplete method implementation.
// Return the number of rows in the section.
return 0;
}
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
static NSString *CellIdentifier = @"HelloCell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil){
    cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:CellIdentifier];
}
cell.textLabel.text = @"Hello";
// Configure the cell...
return cell;
} 
 谁能告诉我如何使用tableview&控制器?
我确实经历了几个文档和示例,但实际上无法理解
您需要指定表视图的行和节数.像这样.- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
    {
        #warning Potentially incomplete method implementation.
        // Return the number of sections.
        return 1;
    }
    - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
    {
    #warning Incomplete method implementation.
    // Return the number of rows in the section.
    return [sourceData Count]//i.e., 10;
    }
    - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
    {
    static NSString *CellIdentifier = @"HelloCell";
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
    if (cell == nil){
        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:CellIdentifier];
    }
    cell.textLabel.text = @"Hello";
    // Configure the cell...
    return cell;
    }
        
             