Hi all!

 

I am using the iterator of checkboxes in order to clear all the checkboxes in a page…

 

$browser.checkboxes.each do |check|

      check.clear

end

 

 

But, this is taking too much processing time… I was thinking that maybe if I check if the checkbox is CHECKED, this could be done in less time…

 

But, I can’t access the .checked propertie of a checkbox right?

 

I’ve tried this:

 

$browser.checkboxes.each do |check|

   if check.checked==true then

      check.clear

   end

end

 

and the output was:

 

test_mejoratiempo:12: undefined method `checked' for #<Watir::CheckBox:0x2e09620> (NoMethodError)

            from test_mejoratiempo:11:in `each'

            from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:2108:in `upto'

            from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:2108:in `each'

            from test_mejoratiempo:11

Execution completed with exit code 1.

 

 

Anyway, do you think this could reduce the processing time? Should I touch Watir.rb in order to see this CHECKED propertie?

 

Thanks in Advance

Cheers, Rodrigo Julian Martin

_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to