Hi Sudeep,

Does the page you are testing have frame sets?
Start an irb session and go to your web page.


Example:

C:\>irb
irb(main):001:0> require 'watir'
=> true
irb(main):002:0> ie = Watir::IE.new
=> #<Watir::IE:0x28b3038 url="about:blank" title="">
irb(main):003:0> ie.goto '1.2.3.4'
=> 5.343
irb(main):004:0> ie.show_frames
there are 3 frames
frame  index: 1 name: companyArea
frame  index: 2 name: tabArea
frame  index: 3 name: infoArea
=> 0..2
irb(main):005:0>


You can also search this site for WebMetrics. It's supposed to be a
recorder but recorders are bad. It is a nice helper tool for beginners
because it will show you what a nested expression looks like for
Watir. Don't expect to record and play back scripts. It ain't gonna
happen.



Regards,
Darryl



On Dec 8, 1:35 am, sudeep pattnaik <sudeeppattn...@gmail.com> wrote:
> Hi,
>
> The page I am testing, gets loaded after the login page. I have written
> Watir script for logging in also which works fine.
> The problem is Watir scxript is not able to locate any of the elements on
> the page even if I have tried to access them using different parameters like
> :name,:id,:text etc.
>
> Is there any specific reasons for this?
>
> Initially I thought my Ruby installation got corrupted, but surprsingly it
> works fine for other applications.
>
> Please advise.
>
> Thanks in advance.
>
> Regards,
> Sudeep
>
> On Mon, Dec 6, 2010 at 7:38 PM, sudeep pattnaik 
> <sudeeppattn...@gmail.com>wrote:
>
> > Hi Željko,
>
> > You are right. when the page is loaded, the select is there and the value
> > in it is "none" and by default it gets set to "Operational Control" in a
> > span of 2 secs.
>
> > So I think I have to make the control wait for the time till the value gets
> > changed to "Operational Control" and then set it to "Audits".
>
> > Sudeep.
>
> > On Mon, Dec 6, 2010 at 7:22 PM, Željko Filipin <
> > zeljko.fili...@wa-research.ch> wrote:
>
> >> On Mon, Dec 6, 2010 at 2:42 PM, Sudeep <sudeeppattn...@gmail.com> wrote:
> >> > browser.select_list(:name,"ModuleID").set("Audits")
> >> > <option value="13">&nbsp;&nbsp;&nbsp;Audits
>
> >> Maybe one of these would work:
>
> >> browser.select_list(:name,"ModuleID").set("   Audits")
> >> browser.select_list(:name,"ModuleID").set(/Audits/)
>
> >> Does this flash the select list?
>
> >> browser.select_list(:name,"ModuleID").flash
>
> >> Is the select list on the page? Maybe it appears later, or it is hidden.
>
> >> Željko
>
> >>  --
> >> Before posting, please readhttp://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<watir-general%2bunsubscr...@googlegroups.com>

-- 
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

Reply via email to