36件ヒット
[1-36件を表示]
(0.017秒)
別のキーワード
種類
- クラス (12)
- インスタンスメソッド (12)
- 特異メソッド (12)
ライブラリ
- win32ole (36)
クラス
-
WIN32OLE
_ EVENT (24)
キーワード
-
WIN32OLE
_ EVENT (12) - handler= (12)
検索結果
-
WIN32OLE
_ EVENT . message _ loop -> () (18125.0) -
Windowsのメッセージポンプを実行します。
...Windowsのメッセージポンプを実行します。
message_loopメソッドは、Windowsメッセージがキューイングされている限りメッ
セージの読み出しとディスパッチを実行します。
COMのスレッド間/プロセス間通信はスレッド内で呼び出......処理は
Windowsメッセージを読み取ってディスパッチすることで通知されます。
ie = WIN32OLE.new('InternetExplorer.Application.1')
event = WIN32OLE_EVENT.new(ie, 'DWebBrowserEvents2')
b = false
event.on_event('DocumentComplete') do |disp, uri|
disp.document.get......oads/ など
end
disp.quit
b = true
end
ie.Navigate2 'http://www.ruby-lang.org/ja/'
loop do
break if b
WIN32OLE_EVENT.message_loop
end
なお、メソッド名はloopですが、呼び出し時および既にキューイングされたメッ
セージの処理中にキ... -
WIN32OLE
_ EVENT (12.0) -
OLEオートメーションサーバからのイベント通知を制御するクラスです。
...イベントを受け取るメソッドをサーバへ登録できま
す。
=== サンプルコード
ie = WIN32OLE.new('InternetExplorer.Application.1')
event = WIN32OLE_EVENT.new(ie, 'DWebBrowserEvents2')
b = false
event.on_event('DocumentComplete') do |disp, uri|
disp.document.getE......lementsByTagName('a').each do |e|
puts "#{e.innerHTML}=#{e.href}" #=> ダウンロード=http://www.ruby-lang.org/ja/downloads/ など
end
disp.quit
b = true
end
ie.Navigate2 'http://www.ruby-lang.org/ja/'
loop do
break if b
WIN32OLE_EVENT.message_loop
end... -
WIN32OLE
_ EVENT # handler=(obj) -> () (12.0) -
イベント処理を実行するオブジェクトを登録します。
...ie = WIN32OLE.new('InternetExplorer.Application.1')
event = WIN32OLE_EVENT.new(ie, 'DWebBrowserEvents2')
event.handler = IeHandler.new
ie.Navigate2 'http://www.ruby-lang.org/ja/'
loop do
break if event.handler.completed
WIN32OLE_EVENT.message_loop
end
ie.Quit
WIN32OLE_EVENT#on_...