N
nondos
Hello
I have a thread that run loop in queue variable like this:
For each <something> as <something> in <queue variable>
Next
And the thread and the loop work fine
I have problem when i want to add something to the queue and the thread is
running i get error message "Collection was modified; enumeration operation
may not execute." Is there any way to solve this? I thought about this:
For I=1 to queue.count
Next
And when the loop end check if there's new items on queue
But I prefer if there is another solution with first loop
Thanks
P.S sorry for my English
I have a thread that run loop in queue variable like this:
For each <something> as <something> in <queue variable>
Next
And the thread and the loop work fine
I have problem when i want to add something to the queue and the thread is
running i get error message "Collection was modified; enumeration operation
may not execute." Is there any way to solve this? I thought about this:
For I=1 to queue.count
Next
And when the loop end check if there's new items on queue
But I prefer if there is another solution with first loop
Thanks
P.S sorry for my English