UITableView - expanding cells [duplicate]
-
07-03-2021 - |
سؤال
I managed to expand my cell (after many tries) as you can see in my pic.
but what I really want is something like this:
as you can see when the user click on description the cell expand showing the content:
Can please somebody tell me where I can find all the info to do that. (I struggling to find them). thank you very much!!!!!!
المحلول
You can try apple's source code in your application- http://developer.apple.com/library/ios/#samplecode/TableViewUpdates/Introduction/Intro.html
or you can fallow this blog -
http://www.cocoanetics.com/2011/03/expandingcollapsing-tableview-sections/
and you need to add custom UITableViewCell design as per your need.
نصائح أخرى
Change the height of the cell in tableView:heightForCellAtIndexPath:
, change the cell layout in tableView:cellForRowAtIndexPath:
and call [[self tableView] reloadData];
.