hi
i have a list with different objects (type objects) and i make a check if an item IS x then do something.
i just noticed that a loop with about 300 items will take about 200ms. that's quite long for such a small list.
why dows the IF...IS statement takes so long?? is there a different way i could check if an item is a specific object and then do something??
just for comparison, a list with 1000 items without checking if IS and go through all in a loop will take less then 1ms.
thanx, ilan
i have a list with different objects (type objects) and i make a check if an item IS x then do something.
i just noticed that a loop with about 300 items will take about 200ms. that's quite long for such a small list.
why dows the IF...IS statement takes so long?? is there a different way i could check if an item is a specific object and then do something??
just for comparison, a list with 1000 items without checking if IS and go through all in a loop will take less then 1ms.
thanx, ilan