aspose file tools*
The moose likes Java in General and the fly likes Automatic Keystrokes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Automatic Keystrokes" Watch "Automatic Keystrokes" New topic
Author

Automatic Keystrokes

Jason Chester
Greenhorn

Joined: Aug 31, 2006
Posts: 1
Hey all, I'm working on a web page using Java with a control on the page. I'm trying to get rid of the stupid "press spacebar to activate this control" message and decided to run a method which would automatically have the program press spacebar or enter. However, I'm having a hard time figuring out how to get it to work. I'm approaching it with

keybd_event(VK_ENTER) or
keyPress(KeyEvent.VK_ENTER);

but can't seem to get it to work. Let me know if you have any help...
Jason
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
java.awt.Robot
 
 
subject: Automatic Keystrokes