i am writing one app in that app i have to display tableview with two cells.while the first cell touched by the user then it have to show some other cells within the view (i cant use navigation here) and also second cell also visible..can any one tell me the suggestion for this.
thank you all.
i am writing one app in that app i have to display tableview with
Share
If you want to insert table view cells when you are clicking on a cell, try the following code.
Lets consider you are going to insert 3 rows in the position 1, 2 and 3 in the section 0. In the didSelectRowAtIndexPath method, do the following. Here the rows will be inserted in section 0, if we select row 0(first row) in section 0(first section).
In your numberOfRowsInSection method, you should be having something like the following,
And make sure you are having appropriate code in cellForRowAtIndexPath method to display content in the newly displayed rows.
Note: You have to alter your code in such a way that the rows are not inserted when clicking the row 0 of section 0, when they are already been inserted.