Think you could replace tbody with table, since the first table in the div has 
the text fields





On Friday, November 15, 2013 2:42 AM, QOExcel <[email protected]> wrote:
 
Yes. I use 'cheesy' gem. It is pity, but this implementation doesn't work 
.tbody isn't understood as a method here. 

пятница, 15 ноября 2013 г., 0:05:43 UTC+4 пользователь johnssn написал:
That last comment I made wasn't right since you're trying to get to the text 
field. Maybe this instead (sorry, haven't used that library)
>
>
>
>
>text_field(:my_text_field, :class=>'modal-dialog-content' ). 
>tbody(:index=>0).text_field(: index=>0)
>
>
>
>On Thursday, November 14, 2013 6:55 AM, John Fitisoff <[email protected]> 
>wrote:
> 
>That's a really good question. I think you're talking about the 'cheesy' gem 
>and I think that it does some sort of normalization between watir and 
>selenium. Maybe this will work (collections are stripped out):
>
>
>div(:my_div, :class=>'modal-dialog-content' ). tbody(:index=>0).text_field(: 
>index=>0)
>
>
>
>On Thursday, November 14, 2013 1:02 AM, QOExcel <[email protected]> wrote:
> 
>Thank you very much for your help!! I will read beforehand 
>http://watir.com/support .... 
>It works actually .. But i use Page Object style for writing code, something 
>like this:
>
>span(:find_replace_dialog_ matchcase_checkbox_3,:id => 'find-replace-regex') or
>button(:find_replace_dialog_ done_button, :name => 'done') 
>
>Can i convert b.div(:class, 'modal-dialog-content'). tbodys[0].text_fields[0] 
>to style of Page Object ?
>
>среда, 13 ноября 2013 г., 19:52:29 UTC+4 пользователь johnssn написал:
>You almost never need to resort to xpath if you're using watir. Something like 
>this?
>>
>>b.div(:class, 'modal-dialog-content'). tbodys[0].text_fields[0]
>>
>>b.div(:class, 'modal-dialog-content').
tbodys[0].text_fields[1]
>>
>>
>>
>>
>>
>>
>>On Wednesday, November 13, 2013 3:55 AM, QOExcel <[email protected]> wrote:
>> 
>>Hello, All
>>I have to find a couple
 locators (textboxes).They have the same <class> so i need xpath to find 
definite locator :
>>
>><div class="modal-dialog- content">
>><table>
>><tbody>
>><tr>
>><td class="waffle-find- replace-dialog-label">
>><label id=":j6.findLabel">Find </label>
>></td>
>><td>
>><input class="jfk-textinput" s tyle="width: 20em;" aria-labelledby=":j6. 
>>findLabel">
>></td>
>></tr>
>><tr>
>><td class="waffle-find- replace-dialog-label">
>><td>
>><input class="jfk-textinput" s tyle="width: 20em;" aria-labelledby=":j6. 
>>replaceLabel">
>></td>
>></tr>
>><tr>
>><tr>
>></tbody>
>></table>
>></div>
>>I can find <modal-dialog-content> by such request : div(:test_el1, :xpath => 
>>'//div[@class="modal-dialog- content"]') but i can't define lower elements 
>>through this request. What i mean actually :  div(:test_el1, :xpath => 
>>'//div[@class="modal-dialog- content"]/table/tbody/tr/td[2] ')
>>Does anybody
 know  solution for this?
>>
>>
-- 
>>-- 
>>Before posting, please read http://watir.com/support. In short: search before 
>>you ask, be nice.
>> 
>>[email protected]
>>http://groups.google.com/ group/watir-general
>>watir-genera...@ googlegroups.com
>> 
>>--- 
>>You received this message because you are subscribed to the Google Groups 
>>"Watir General" group.
>>To unsubscribe from this group and stop receiving emails from it, send an 
>>email to watir-genera...@ googlegroups.com.
>>For more options, visit https://groups.google.com/ groups/opt_out.
>>
>>
>>
>>
>>
>-- 
>-- 
>Before posting, please read http://watir.com/support. In short: search before 
>you ask, be nice.
> 
>[email protected]
>http://groups.google.com/ group/watir-general
>watir-genera...@ googlegroups.com
> 
>--- 
>You received this message because you are subscribed to the Google Groups 
>"Watir General" group.
>To unsubscribe from this group and stop receiving emails from it, send an 
>email to watir-genera...@ googlegroups.com.
>For more options, visit https://groups.google.com/ groups/opt_out.
>
>
>
>
>
>-- 
>-- 
>Before posting, please read http://watir.com/support. In short: search before 
>you ask, be nice.
> 
>[email protected]
>http://groups.google.com/ group/watir-general
>watir-genera...@ googlegroups.com
> 
>--- 
>You received this message because you are subscribed to the Google Groups 
>"Watir General" group.
>To unsubscribe from this group and stop receiving emails from it, send an 
>email to watir-genera...@ googlegroups.com.
>
>For more options, visit https://groups.google.com/ groups/opt_out.
>
>
>
>
-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.
 
[email protected]
http://groups.google.com/group/watir-general
[email protected]
 
--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

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

[email protected]
http://groups.google.com/group/watir-general
[email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to