how to scroll table on the click event of some cell in objective c?
- by Sarah
Hello friends,
I am right now working with one application where i need to take one uitableview with uilable and textfield in each cell.I am able to scroll the table manually once the user starts writing, but what i want is that when i click on the textfield,the table should scroll upward so that the user is able to see what he has entered in the textfield.Same thing i saw once i logged in the iphone facebook.
this is the code for manually scrolling the table :
- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section
{
return 250;
}
-(UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section
{
CGRect viewRect = CGRectMake(0, 0, 320, 160);
UIView *footerView = [[UIView alloc] initWithFrame:viewRect];
return footerView;
}
Is there any way around?
Thanks in advance.