My script works perfectly in record and run mode. But when I run it as compiled and run as ".exe", I get such an error "Script finished with error : SyntaxError: Parse error during execution".
Create a variable called "counter". Than use "is element exist" to check if element exist and update "counter" variable whenever element is missing. Check counter variable in the loop, and fail thread if "counter" hit 3