http://wiki.openqa.org/display/WTR/How+to+wait+with+Watir

I've used this:

  while (not $ie.html.include? "my html")
    <code to refresh page.-- won't auto-update>
    puts "not there yet  ..."
    sleep 5
  end

You can also use $ie.text.include? & there are probably other ones
too, but that's all I seem to need.
You could also put in a timeout limit as well.


Kim


On Nov 30, 2:39 pm, QAguy <qablogm...@gmail.com> wrote:
> I have this piece of code on a page I am trying to script against.
>
> <div style="" id="encoding_success" class="encoding_complete">
> <p>
> <strong>Done!</strong>
> <a id="video_url_link" href="/video/show/4e9dd3b81c1cc3">Go to your
> video<img src="/images/pixel.gif?1246941735" class="icon
> double_arrow_icon" alt="Pixel"/></a>
> </p>
> </div>
>
> This div always exists, but it not always VISIBLE on the page. I want
> to create a wait until this element is visible on the page but not
> sure how to do this?
>
> Was thinking something like this but doesn't seem to work:
>
> Watir::Waiter::wait_until { @browser.div(:class,
> 'encoding_complete').visible? == true} but it doesn't work as I think
> the use of visible here is invalid. Hoping someone help me.
>
> Thanks
> QAguy

-- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general

Reply via email to