> Thanks, Mark and Michael. I'm glad to have the frame handle business
> explained. Unfortunately, the text is still not being found at either
> the frame level or the browser level.
>
> If I look for text (using xx.text.include?) at the browser level,
> should I expect it to be found regardless of the presence of other
> structures, like frames or tables? In other words, if the text is
> present inside of a frame, should I have to search using the frame
> handle or should a browser level search find the text as well?
If the text is present inside of a frame, you will need to search using the
frame handle. And if there are nested frames, you will have to dig down to
the correct level.
Are you aware of irb? I use it a lot when writing my tests. It is the
interactive ruby browser. Here is a quick example of how I used it to
confirm the answer to your question:
C:\Documents and Settings\manderson>irb
irb(main):001:0> require 'Watir'
=> true
irb(main):002:0> ie = Watir::IE.new
=> #<Watir::IE:0x...
[This brings up my IE browser]
[Then I can navigate manually to the page I'm working with]
irb(main):003:0> ie.text.include? "admin page"
=> false
irb(main):004:0> ie.show_frames
there are 2 frames
frame index: 1 name: menuFrame
frame index: 2 name: bottomFrame
=> 0..1
irb(main):005:0> ie.frame(:name, "bottomFrame").text.include? "admin page"
=> true
__________ Information from ESET NOD32 Antivirus, version of virus signature
database 3804 (20090127) __________
The message was checked by ESET NOD32 Antivirus.
http://www.eset.com
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Watir General" group.
To post to this group, send email to [email protected]
Before posting, please read the following guidelines:
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/watir-general
-~----------~----~----~----~------~----~------~--~---