I have an array with 2000 arrays, each of which has 2000 values ββ(to accommodate a 2000x2000 image) in javascript in HTA. I have this code to check how many "blue" values ββare in the array (array name is image ):
var bluePixels = 0; for(i = 0; i < image.length; i++){ for(j = 0; j < image[i].length; j++){ if(image[i][j] == "blue"){bluePixels = bluePixels + 1} } } alert(bluePixels);
The problem is that it shows a message that says something like "Stop execution of this script? Script on this page slows down Internet Explorer. If it continues, your computer may not respond." (Iβm not sure about the exact words because my computer is in French), and then if I click βnoβ, it does alert(bluePixels) as it should, but if I click βyesβ, itβs not . How to block this message? (I know that there are workarounds, for example, when the user first says no, but I want a real solution)
javascript arrays
Donald Duck Jan 25 '15 at 12:01 2015-01-25 12:01
source share