emu Posted April 22, 2005 Share Posted April 22, 2005 ok well i need to have the script hold down shift + down for x amount of seconds and then shift + rigth for x amount of seconds i know there is the "Send("{a down}")" but how do i make it only for so many seconds? Link to comment Share on other sites More sharing options...
CyberSlug Posted April 22, 2005 Share Posted April 22, 2005 (edited) Try the following:$x = 5000 ;number in milliseconds; adjust as neededOpt("SendKeyDownDelay", $x)Send("+{Down}")Send("+{Right}")Read the Send documentation if you have any questions.In case the above doesn't work like I expect:$t = 5000;time in milliseconds $init = TimerInit() Send("{ShiftDown}{RIGHT down}") While TimerDiff($init) < $t sleep(10) WEnd Send("{RIGHT up}{ShiftUp}") Edited April 22, 2005 by CyberSlug Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! Link to comment Share on other sites More sharing options...
emu Posted April 22, 2005 Author Share Posted April 22, 2005 well i need them to be held down for a differnet amount of time Link to comment Share on other sites More sharing options...
CyberSlug Posted April 22, 2005 Share Posted April 22, 2005 (edited) well i need them to be held down for a differnet amount of time<{POST_SNAPBACK}>Then why did you use the variable x in both cases? Opt("SendKeyDownDelay", 123)Send("+{Down}")Opt("SendKeyDownDelay", 456)Send("+{Right}")I also modified my above post to offer a different possibility. Edited April 22, 2005 by CyberSlug Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig! Link to comment Share on other sites More sharing options...
emu Posted April 22, 2005 Author Share Posted April 22, 2005 (edited) heh sry i didnt think about it ty for help though also is the "123" "456" in milliseconds or what Edited April 22, 2005 by emu Link to comment Share on other sites More sharing options...
Recommended Posts