Rodrigo,

Examining the HTML I see that the image with id of "img2" isn't even in 
the div with id "DIVImageFile_2". In addition, the img2 image doesn't 
have any events associated with it, so clicking that image won't do 
anything.

I think the link you wish to follow is the link following img2:

<a href="javascript:quitar(2)" id="quitar2" 
style="visibility:hidden">Quitar</a>

Try:

$browser_popup.frame('responseFrame').link(:id, 'quitar2').click

to click the link following the img2 image.

David Schmidt
[EMAIL PROTECTED]

Rodrigo Julian Martin wrote:
>
> Thanks for the answer Lonny, and sorry for that untidy HTML! I’ll 
> download TidyUI…
>
> I’m trying to click the image with this:
>
> $browser_popup.frame(:name,"responseFrame").div(:id, 
> "DIVImageFile_2").image(:id, "img2").click
>
> And the output shows:
>
> c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:856:in `getImage': undefined 
> local variable or method `document' for #<Watir::Div:0x3333558> 
> (NameError)
>
> from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:2690:in `initialize'
>
> from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:608:in `new'
>
> from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:608:in `image'
>
> from subir_fotos:27
>
> Or directly with this sentence…
>
> $browser_popup.image(:id,"img2").click
>
> That sentence doesn’t throw any error, but it doesn’t click the image 
> as the popup that should appear doesn’t….
>
> Any help would be really appreciated..
>
> Thanks in Advance!
>
> Rodrigo Julian Martin
>


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

Reply via email to