|
What you’re seeing is correct. What is happening
with the command prompt window it is scrolling through all of the active
windows objects on your machine trying to match the window title bar text.
The clicker starts a new process (command prompt window) since a JS alert is
modal otherwise the JS Alert would never get clicked. If the command
prompt window bothers you could change the line in startClicker by adding a ‘w’
after ruby: c = "start rubyw
#{shortName}\\watir\\clickJSDialog.rb #{button} #{waitTime} " Hope this helps, --Mark From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ryan Howard (Intern) I am trying to use the startClicker method to click on a
popup box. The code is absolutely correct, however when the program runs and
the popup appears, another command prompt appears and starts to cycle through a
whole bunch of stuff I’ve never seen before. It’s almost as if I
went into my computer and clicked the actual file. I have also checked, and I
am calling the method at the right time. Here is what I have. class TC_blogsFrontEnd < Test::Unit::TestCase
def test_15_Blogs_DeleteBlog
$ie = Watir::IE.new()
$ie.goto('http://localhost/cs')
$ie.link(:text, 'Control Panel').click
$ie.link(:text, 'My Blogs').click
$ie.goto('http://localhost/cs/ControlPanel/Blogs/postlist.aspx')
startClicker('Cancel')
$ie.link(:text, 'Delete').click
if $ie.contains_text('Change Post title attempt')
puts "Blogx15 Failed"
else
puts "Blogx15 Passed"
end
$ie.goto('http://localhost/cs/') end def startClicker( button , waitTime = 3) w = WinClicker.new longName = $ie.dir.gsub("/" ,
"\\" ) shortName = w.getShortFileName(longName) c = "start ruby
#{shortName}\\watir\\clickJSDialog.rb #{button} #{waitTime} " puts "Starting #{c}" w.winsystem(c) w=nil end end If yall have any ideas that would be great! J Thanks, - |
_______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
