From: brabuhr@... Date: 2010-06-16T08:00:29+09:00 Subject: Re: Simulating keystrokes for automated user input On Tue, Jun 15, 2010 at 5:45 PM, Ryan Mohr wrote: > I've written a simple console app (type command. get results. repeat.) > and I'm looking for a way to send it simulated keystrokes (hoping to > remotely send commands through a socket connection and have them "typed" > in the main console).  I thought the solution would be easy but I'm > finding it much harder than anticipated. > > The solution needs to generate a keystroke programmatically such that > the console has no idea whether it was physically typed by the user or > not. http://programming.ccp14.ac.uk/expect/ http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/66884 http://java.sun.com/j2se/1.4.2/docs/api/java/awt/Robot.html http://www.devdaily.com/blog/post/ruby/ruby-jruby-program-that-runs-java-robot-class http://www.semicomplete.com/projects/xdotool/