HOw many times this blocks of code in table view gets executed and Why?
(Cell height is 60)
I did print the Orange text in nslog and found that it executes maximum 7 times when i have 20 records in table and 8 times when i have 100 records
(I know it executes 6 times for 6 records which fits in screen)
It has 5 records which fits in screen and some part of 6th record, so it should execute 6 time.. Then why does it executes 7 or 8 time when it can use already created cell.
(Cell height is 60)
I did print the Orange text in nslog and found that it executes maximum 7 times when i have 20 records in table and 8 times when i have 100 records
(I know it executes 6 times for 6 records which fits in screen)
Code:
if(cell == nil){
[COLOR="DarkOrange"]NSLog(@"getcellcontent");[/COLOR]
UITableViewCell *cell = [[[UITableViewCell alloc] initWithFrame:CellFrame reuseIdentifier:cellIdentifier] autorelease];
[cell setSelectionStyle:UITableViewCellSelectionStyleNone];
}
It has 5 records which fits in screen and some part of 6th record, so it should execute 6 time.. Then why does it executes 7 or 8 time when it can use already created cell.
Last edited: