Watir Webdriver rapidly untick all checkboxes?


I have to deal with a web page with over 14000 checkboxes. What I was
doing when the data was slightly smaller was to loop through all of them
and clear if set.
It still caused Firefox to pop up with JavaScript timeouts but if I
clicked the continue button it managed to pull through.

However, now the page is so large that it is causing timeouts even when
counting the number of checkboxes, and clicking continue eventually
causes timeouts.

Is there any way I can search for checkboxes by set? Something like
“browser.checkboxes(:set => true)”?

I’ve tried using JavaScript to loop through all; but because that’s just
a loop that’s causing the same kind of timeouts. I have no control over
the page content, or I’d abolish this awful practice of thousands of


FYI I tried extending Firefox’s JavaScript timeouts. All it seems to do
is stop the script without asking instead. That’s even worse, because
using that method, what used to work by pressing “continue” once in a
while now just doesn’t work at all.