I created a custom UIView, and inside this UIView I add a UITableView, for example:
treeView = [[UITableView alloc] initWithFrame:CGRectMake(0, 80, slider.frame.size.width, slider.frame.size.height - 80)];
[treeView setDelegate:self];
[treeView setDataSource:self];
[self addSubview:treeView];
[treeView release];
When the application loads, the table seems to load fine. However, when I try to scroll through a table, it does not respond to touches at all.
I also implement these methods for delegates / data sources:
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView;
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section;
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath;
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;
Does anyone know why this is so?
thank
source
share