Hello Bulat, "Bulat Ziganshin" <bulatz / integ.ru> wrote in message > you must exec "sync" at both sides :) add after first line > > check.sync = true > > i use this techinque to work with perl.exe and it really works Ok, so now I have: check = IO.popen("ruby c:/ruby/bin/irb.rb",'w+') check.sync = true check.puts("STDOUT.sync = true") check.puts("puts $:") check.readlines.each { |line| puts line unless line =~ 'nil' } check.close_write check.readlines.each { |line| puts line unless line =~ 'nil' } and it still does not work :-(( Can I see your code which drives perl.exe ? May be it has something to do with the target application (in your case "perl.exe" in my case "osql.exe") I am using "irb" only as an example. Thanks, -- shanko