Ios UITableView滚动水平问题
这是我创建tableView的代码:Ios UITableView滚动水平问题,ios,objective-c,uitableview,Ios,Objective C,Uitableview,这是我创建tableView的代码: _tableView = [[UITableView alloc] initWithFrame:CGRectMake(8, 0, self.view.frame.size.width - 16, self.view.frame.size.height - 8) style:UITableViewStylePlain]; [_tableView registerNib:[UINib nibWithNibName:@"commentCell"
_tableView = [[UITableView alloc] initWithFrame:CGRectMake(8, 0, self.view.frame.size.width - 16, self.view.frame.size.height - 8) style:UITableViewStylePlain];
[_tableView registerNib:[UINib nibWithNibName:@"commentCell" bundle:nil] forCellReuseIdentifier:@"commentCell"];
_tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
_tableView.backgroundColor = [UIColor groupTableViewBackgroundColor];
_tableView.dataSource = self;
_tableView.delegate = self;
[self.view addSubview:_tableView];
问题是我的表格水平滚动,我需要知道如何停用它,我尝试过bounce=NO;或contentSize,但始终是同一问题我的表仍允许水平滚动
问题是由my ViewDidDisplay中的[tableView RealLoad]函数引起的,该函数在完成显示allCell之前重新加载我的表格,因此导致了不适当的行为