It does work that way, that's why I'm trying to understand the problem here. When the loop stops it runs the sub events once more, but it would only run it if the condition is true, it would mean the value to stop the loop is found at the end of the array.