Re: [wtr-general] How to access cell or row index using watir-webdriver

2011-05-05 Thread Jari Bakken
On Thu, May 5, 2011 at 10:31 AM, Dan Claudiu Pop
 wrote:

> And also i tried with "each_with_index" but didn't get the expected
> output.
>

That should work.

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


Re: [wtr-general] How to access cell or row index using watir-webdriver

2011-05-05 Thread Željko Filipin
On Thu, May 5, 2011 at 10:31 AM, Dan Claudiu Pop 
wrote:
> And also i tried with "each_with_index" but didn't get the expected

What did you get and what did you expect? Please also provide your code.

Rubydoc says watir-webdriver does not have a method with "index" in name:

http://rubydoc.info/gems/watir-webdriver/

Željko
--
watir.com - community manager
watir.com/book - author
watirpodcast.com - host
viaqa.mobi conference on software testing - organizer

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] How to access cell or row index using watir-webdriver

2011-05-05 Thread Dan Claudiu Pop
Hello,

Can you guide me with some general approaches to get the index of a
row or cell with watir-webdriver ?

I've tried some approaches like:

   @browser.tbody(:index, 0).rows.each do |row|
  if  row.text.include?("#{name}") then
 puts row.row_index
  end
end

And also i tried with "each_with_index" but didn't get the expected
output.

Thank you,
Dan

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com