scrollview loading question

Hello,


I have a viewcontroller with a child scrollview within it. I also have an xib file of a view that holds 10 sections (horizontal) that containa 4 images and a button. For the scrollview I need to load 10 versions of this xib view so that I have 100 sections. Each section is essentially a level that can be clicked to play, and the images show the players score and if the button is enabled, things like that.


So I do this loading in the viewDidLoad function. Then in the viewWillAppear, I make some additional changes to these sections based off some of the players data. I basically have a default set on all sections, then the images might be changed to represent higher score (0-3 stars kind of thing), for example.


So this all functions correctly, the issue is the amount of time it takes to process all this and then segue to the view. When you click to reach this view, it pauses for a few seconds before actually segueing. I have not tested this out on an actual device so I'm not sure about if it will be quicker or slower than the simulator. I would assume it would run quicker. In addition, I'm running a mac vm on a windows box, but it runs fairly good with my setup. I'm looking to invest into a mac mini here in the near future.


I ramble a lot, sorry about the story I just like to be verbose. My question is given my explaination is there anything that stands out as what I can do so that I don't get this delay?


I was brainstorming a few ideas but I don't know how to implement them. 1 would be to figure out how to have it only load what is visible within the scrollview, then as the user scrolls it would load as necessary. 2 I was thinking maybe before I can have everything loaded up when the previous view is loaded. That way when I segue to this view, it is pre-prepped you could say and would load faster.


In both cases, I don't know how to implement them, so I'm asking on here.


Thanks for any comments, I appreciate the help!