I am developing an app which will show some information in a detailview which is fully customized by me.
The information I am showing is:
- an image (from the internet)
- name and date of input
- description (with own detailview)
- additional information (with own detailview)
- button to linked options #1
- button to linked options #2
For my Grouped TableView I am using 12 cells to display this information.
- 3 cells for image (to give it a border (top, body, bottom) by adding cell background) no action, bottom cell also displays name + date
- 1 devider cell (no content, just for adding height) no action
- Title description
- Description with action to detailview of description
- 1 devider cell (no content, just for adding height) no action
- Title of additional info
- Additional info (with custom background) with action to detailview of additional info
- 1 devider cell (no content, just for adding height) no action
- Button to linked options #1 (With custom background image) action to other overview #1
- Button to linked options #2 (With custom background image) action to other overview #2
Some content comes from the internet, however all of the images (except the one in the top of this view) are local images. All used backgrounds are local png files.
Now my question. When the Table loads, the first cells are loaded. But when I scroll down, the rest of the cells gets loaded. Is there a way to completly load this view? And keep its data when scrolling so it doesn’t reload each time you reach the top or bottom of the TableView?
Or do I need to change my layout in to something else?
I couldn’t find anything about this on how to solve it.
Hope someone can help me!
With Kind Regards,
Douwe
-
–
You do not have to worry about it. The whole point of
UITableViewController‘sdatasourcemethods (works like a delegate) is that you specify all the content that you need, and it gets loaded when it is needed. For your programming logic that means that you do not have to care about what exactly get’s loaded when.One trick you can employ is to give each cell its own
CellIdentifier. In this way you can be sure that each cell will load all elements from the data source you specify even if it scrolls on and off the screen.