tags:

views:

24

answers:

1

Hi, all I am doing one chat application, i which i am using uitable view to display reply and response from user.in this case after some interval of time i am reloading my tableview to fetch new data from server. But the problem is that after adding new content to table view it will go at the bottom of table view and i have to scroll table view to see that one.or in other case whenever i am reloading my table it will show its first cell on view. Now my question is "is it possible to load last cell of uitableview after view gets load or reload table view?"

Thanks in advance..

A: 

[sTableView reloadRowsAtIndexPaths:[NSArray arrayWithObject:[NSIndexPath indexPathForRow:sender.tag inSection:0]] withRowAnimation:UITableViewRowAnimationNone];

GhostRider
Thank you for your reply..but the thing here is that i want to load last cell of table view...i am working on one chat application in which whenever new response come from server i have to show it in table view.and new response get appended at the end of table view so i need to load that end over here.i got succes by using scrolltorow at index path but then i am not able to see conten of first cell..
Gaurav aka sparsh
me also have chat application source code and i will check and tell you
GhostRider
[mChatRoomsTableView scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionBottom animated:YES];
GhostRider
hi,i had tried a lot with this but this will not work, rather when i will try this : [self.ChatListTable_obj scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionTop animated:YES];This will work fine but if data is too large it will show autoscrolling..and i dont want that rather i want direct last cell.
Gaurav aka sparsh