开发者

TableView scrolls to bottom and perform some action

In my application there is a table view.What I want to do is when I scrolls the table view and when it come to its end row I want to perform some action. Please tell me which approach should I use to do this. T开发者_C百科hanks in advance!!


I think you should make a check in

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)

when it loads the last row then call that method.

I think this will work. because table does not load all data at once but i loads data when user scroll


I think (don't the docs up here) but there is no method within the UIScrollViewDelegate that handles the scrolling to the bottom. There is when scrolling to top, but can't remember if there is scrolling to bottom. Check it please.

If not, the easy way is just to check the indexpath.row at cellForRow. If it is your last row, call whatever action you want.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜