namedrisk Posted September 27, 2009 Posted September 27, 2009 (edited) Hi, i am trying to send a key to a minimized window using controlsend, i can send all keys but {RIGHT down}... ControlSend("My Window", '', '', "{RIGHT DOWN}") is there a workaround or other method i could use ? Also i have noticed that while it is sending keys it mess up if i use the keyboard in some cases .... Edited September 27, 2009 by namedrisk
gte Posted September 28, 2009 Posted September 28, 2009 Will this work? Hi, i am trying to send a key to a minimized window using controlsend, i can send all keys but {RIGHT down}... ControlSend("My Window", '', '', "{RIGHT}",0) ControlSend("My Window", '', '', "{DOWN}",0) is there a workaround or other method i could use ? Also i have noticed that while it is sending keys it mess up if i use the keyboard in some cases .... HP OpenView ServiceCenter keep alive scriptRemote Desktop Login Script
namedrisk Posted September 28, 2009 Author Posted September 28, 2009 (edited) Will this work?inst default 0 and raw 1?tryingyes it does not work as i tough it sends any key fine but RIGHT KEY DOWN Edited September 28, 2009 by namedrisk
gte Posted September 28, 2009 Posted September 28, 2009 Can you send them separate? With two different controlsend lines, like I had?inst default 0 and raw 1?tryingyes it does not work as i tough it sends any key fine but RIGHT KEY DOWN HP OpenView ServiceCenter keep alive scriptRemote Desktop Login Script
namedrisk Posted September 28, 2009 Author Posted September 28, 2009 (edited) Can you send them separate? With two different controlsend lines, like I had?like i said on the update it does not work i tried it the way you asked me to, but thanks a lot man ... every key works just fine but keys i send as DOWN or UP when the window is minimized Edited September 28, 2009 by namedrisk
bo8ster Posted September 29, 2009 Posted September 29, 2009 Try ControlSend("My Window", '', '', "{RIGHT} {DOWN}"). I assume you are trying to hold the right arrow key down for some reason. Post your code because code says more then your words can. SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y. Use Opt("MustDeclareVars", 1)[topic="84960"]Brett F's Learning To Script with AutoIt V3[/topic][topic="21048"]Valuater's AutoIt 1-2-3, Class... is now in Session[/topic]Contribution: [topic="87994"]Get SVN Rev Number[/topic], [topic="93527"]Control Handle under mouse[/topic], [topic="91966"]A Presentation using AutoIt[/topic], [topic="112756"]Log ConsoleWrite output in Scite[/topic]
namedrisk Posted September 29, 2009 Author Posted September 29, 2009 Try ControlSend("My Window", '', '', "{RIGHT} {DOWN}"). I assume you are trying to hold the right arrow key down for some reason.Thanks man i will try it out but from my understanding it will send both, the RIGHT key and the DOWN key and will not work as i want but i will try it right now... and update this topic
bo8ster Posted September 29, 2009 Posted September 29, 2009 Not sure what you are trying to do, what keys are you trying to simulate? Post your code because code says more then your words can. SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y. Use Opt("MustDeclareVars", 1)[topic="84960"]Brett F's Learning To Script with AutoIt V3[/topic][topic="21048"]Valuater's AutoIt 1-2-3, Class... is now in Session[/topic]Contribution: [topic="87994"]Get SVN Rev Number[/topic], [topic="93527"]Control Handle under mouse[/topic], [topic="91966"]A Presentation using AutoIt[/topic], [topic="112756"]Log ConsoleWrite output in Scite[/topic]
namedrisk Posted September 30, 2009 Author Posted September 30, 2009 im just trying to send RIGHT DOWN for 500 miliseconds then RIGHT UP to a game window... but it does not work, i mean all keys works but if i want it to be {KEY down} or {KEY up} it will not work
omikron48 Posted September 30, 2009 Posted September 30, 2009 You could try Opt("SendKeyDownDelay", 500). Only thing is, it also makes other key presses last 500ms.
namedrisk Posted September 30, 2009 Author Posted September 30, 2009 You could try Opt("SendKeyDownDelay", 500). Only thing is, it also makes other key presses last 500ms.thx will try that out, i mean i could make it before and change it after so it would not affect the others keys...will post back a feed back thanks
Mison Posted September 30, 2009 Posted September 30, 2009 (edited) try Send("{down 500}") send down arrow keystroke x 500... I wonder why Send("{down down}") is not working... In the help file it states that: To hold a key down (generally only useful for games) Send("{a down}") ;Holds the A key down Send("{a up}") ;Releases the A key but if you run Send("{a down}"), "a" key will be pressed(and released) just once... just like Send("a").. why? a bug? Edited September 30, 2009 by Mison Hi ;)
Mison Posted September 30, 2009 Posted September 30, 2009 doesn't work too.. by the way, {shiftdown} works fine and gives expected result Hi ;)
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