i have a loop that looks like this
for(int x=0; x < 10; x++){
[testLabel setText:[self randomString]];
sleep(1);
}
The randomString is a method where it returns a random string from an array.
I'm using sleep so it is actually possible to see the label being changed.
The loop works fine but the label only gets updated after the last iteration from the loop.
Does anyone know why this could be? And would there be a way to fix it?
See Question&Answers more detail:os