Hi, I am writing script for a testcase below.
1. Open Link abc.htm 2. Click link "chat me" on abc.htm 3. Enter text in the testfield on the newly opened page 4. Click submit button While written script for above like this # Reuired libraries require 'watir' site_text = "http://localhost:8080/XXX/a.htm" ie = Watir::IE.new ie.goto(site_text) ie.link(:text,"Chat me").click ie.text_field(:name,"entry").set "abc" # text field on the opened link I get below error messge : `assert_exists': Unable to locate element, using :name, "entry" (Watir::Exception::UnknownObjectException) from C:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.5/lib/watir/element.rb: 288:in `enabled?' from C:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.5/lib/watir/element.rb: 60:in `assert_enabled' from C:/ruby/lib/ruby/gems/1.8/gems/watir-1.6.5/lib/watir/ input_elements.rb:327:in `set' from D:/Ruby/rbC1.tmp:15 Complete(1) The problem could be because of the new browser window. if yes then how to access objects e.g textfield in the browser i.e. opened by clicking the link in another browser -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. You received this message because you are subscribed to http://groups.google.com/group/watir-general To post: [email protected] To unsubscribe: [email protected]
