in reply to Target method with Selenium::Screenshot

Your code does not match the documentation. The target option does not take an array reference but a hash reference.

Instead of

target => [{ size => { width => 65, height => 12 }, #=> $elem->get_size, location => { x => 35, y => 5 }, #=> $elem->get_element_loc +ation_in_view }]

pass a hash reference:

target => { size => { width => 65, height => 12 }, #=> $elem->get_size, location => { x => 35, y => 5 }, #=> $elem->get_element_loc +ation_in_view }

Replies are listed 'Best First'.
Re^2: Target method with Selenium::Screenshot
by Chaoui05 (Scribe) on May 31, 2016 at 09:16 UTC

    Hello !

    Thanks for reply Corion

    Perfect it works now even if i have nothing displayed in my Shell. I will dig again.

    So for "exclude" we need to pass in an array the size and location?!

    Thanks again

    *****Lost in translation****TIMTOWTOI****
        I will see that with module's author if it's possible. Thanks
        *****Lost in translation****TIMTOWTOI****