Donaldo Posted July 6, 2008 Share Posted July 6, 2008 Hello. I'm new the autoit and I have a question. I understand the command. MouseClick("right", 500, 452, 1, 20) Presses right click on moust for 1 second on coordinate 500, 452. I still don't know what 20 is. But how do I use keyboard? I tried KeyPress("s", 5) What I'm trying to do is press S button for 5 seconds. Anyone can give me a hand? Link to comment Share on other sites More sharing options...
Clipper34 Posted July 6, 2008 Share Posted July 6, 2008 Hey there Donaldo, the 20 represents the speed of the click. Meaning the number you've set is how much it is delayed. And for pressing a key or simulating keystrokes try this code: Send("{S}") Sleep(5000) Send("{S up}") Hope that helps, Clipper34. Link to comment Share on other sites More sharing options...
Donaldo Posted July 6, 2008 Author Share Posted July 6, 2008 Hey thanks for the reply. I tried your code. Send("{S}") Sleep(5000) Send("{S up}") What it did was pressed S for split second, then waited 5 seconds. Then pressed S again. What I want to do is press and hold S key for 5 seconds. Can you give me a hand again? Link to comment Share on other sites More sharing options...
picaxe Posted July 6, 2008 Share Posted July 6, 2008 Try Send("{S down}") Sleep(5000) Send("{S up}") Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now