1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/test/win32ole/err_in_callback.rb
suke 22fe262119 * test/win32ole/test_err_in_callback.rb: InternetExplorer should
be closed.

* test/win32ole/err_in_callback.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19284 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-10 12:15:04 +00:00

15 lines
299 B
Ruby

require 'win32ole'
ie = WIN32OLE.new('InternetExplorer.Application')
ie.visible = true
WIN32OLE_EVENT.message_loop
sleep 0.2
ev = WIN32OLE_EVENT.new(ie)
ev.on_event('NavigateComplete2') {|*args|
foo
}
ie.navigate(ARGV.shift)
while ie.readystate != 4
WIN32OLE_EVENT.message_loop
sleep 0.2
end