Xephon Posted February 4, 2007 Share Posted February 4, 2007 (edited) I need an autoit script that does these simple things. Holds "Ctrl" for 3 minutes Release Ctrl Holds "Shift" For 5 Seconds Release Shift And Infinite Repeats. If anyone have some time, can you please write down the commands for this. Thankyou very much. Edited February 4, 2007 by Xephon Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 4, 2007 Moderators Share Posted February 4, 2007 (edited) http://www.autoitscript.com/autoit3/docs/functions/Send.htmhttp://www.autoitscript.com/autoit3/docs/i.../lang_loops.htmEdit:Also: http://www.autoitscript.com/autoit3/docs/f...ItSetOption.htm Edited February 4, 2007 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Xephon Posted February 4, 2007 Author Share Posted February 4, 2007 (edited) Global $PausedHotKeySet("{INSERT}", "Trigger")HotKeySet("{PAUSE}", "TogglePause")HotKeySet("{END}", "END")While 1 Sleep(100)WEnd//////////////////////////////////////////////////////////////Func Trigger ()While 1 Everythings working fine except this area. I wanted "b" to be held down for Send ("{b down}") 3 minutes then released..... Sleep (180000) After "b" is realeased, I want "n" to be held down for 5 seconds and then Send ("{b up}") released. after that the process repeats until i hit "pause". Sleep (1000) how can i get this reapeating? Send ("{n down}") Can someone edit the script to work correctly, thankyou. Sleep (5000) Send ("{n up}") Sleep (1000)WEnd ExitEndFunc ;==>_Func/////////////////////////////////////////////////////////////////Func TogglePause() $Paused = NOT $Paused Send ("{b up}") Send ("{n up}") While $Paused sleep(100) ToolTip('Script is "Paused"',0,0) WEnd ToolTip("")EndFuncFunc END () Send ("{b up}") Send ("{n up}") ExitEndFunc Edited February 4, 2007 by Xephon Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 4, 2007 Moderators Share Posted February 4, 2007 Sleep uses milliseconds 1000 milliseconds = 1 second, so 60000, would = 1 minute thus Sleep(180000) = approximately 3 minutes. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. 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