I need to add a new row in the tableview when i select a row in the table.
Am i suppose to use the following method???
- (void)insertRowsAtIndexPaths:(NSArray *)indexPaths withRowAnimation:(UITableViewRowAnimation)animation
What shoud i write inside the method to add a new row.?
Please do help me,
Thanks in advance Shibin.
reload data is nice and simple, but does not animate as far as I can tell...
When I add a row dynamically, I use insertRowsAtIndexPaths: here is an example function
If you are filling your table from an array, you can just add an element to your array and call
[myTable reloadData]
ReloadData can add row in teble view but if you want some animation when row add then you should use these lines of code.