provi Posted January 23, 2011 Share Posted January 23, 2011 (edited) Hi, as the topic title says: WinWaitActive("Audi") Send("{F1}") This works, but: ControlSend("Audition", "", "", "{F1}") Does not work. If it is a string, it will work (it will tpye some text). But the "F1" key does not work. And I want to do it so the windows I want to send the keystroke does not need to be focused. Thats why I am trying with ControlSend. WinWaitActive("Audi") ControlSend("Audition", "", "", "{F1}") This is also, not working. I tried with the flag on, but it seems its not working with special keys, am I right? Any ideas? Edited January 23, 2011 by provi Link to comment Share on other sites More sharing options...
Thopaga Posted January 24, 2011 Share Posted January 24, 2011 (edited) ControlSend("Audition", "", "", "{F1}") This should work if the window Audition responds to F1. Could you try to compile(make exec) and try some other Fx button ? You can also try F1 on NotePad. Edited January 24, 2011 by Thopaga Spoiler Sort a multi-dimensional array with multiple sort columns. Max 9 dimensions. Link to comment Share on other sites More sharing options...
Newb Posted January 24, 2011 Share Posted January 24, 2011 $x=WinGetHandle("Audition");Try both Audi or Audition here WinWaitActive("Audi") ControlSend("$x, "", "", "{F1}") Maybe? I'm a compulsive poster. When I post something, come to read it at least 5 minutes later after the posting, because I will edit it. I edited even this signature a few minutes later after I wrote it. Link to comment Share on other sites More sharing options...
provi Posted January 24, 2011 Author Share Posted January 24, 2011 (edited) Tried in NotePad, the F1 function works. Tried other Fx buttons that should trigger something in the window Audition, but nothing happens. However, writing a string and {ENTER} will work with controlsend. BUT I think I managed to narrow down the problem...maybe. I have found that those keys actually use directInput, and the string does not. I guess directinput works with send BUT is unable to work with controlsend. Edit: The above code won't work either. ControlSend won't work with Fx buttons. Wether the window is active or not, controlsend does not work. And I know I can do it with send, but I am trying to not lose focus of what I am currently doing in my computer. Also, is there a way to send the F1 key with RAW mode in controlsend? Edited January 24, 2011 by provi Link to comment Share on other sites More sharing options...
Varian Posted January 24, 2011 Share Posted January 24, 2011 Just out of curiosity, is this Adobe Audition? I have 3.0 and the ControSend() works(brings up the help in the default browser). I noticed in your first post, you had different titles for your WinWaitActive() and ControlSend() lines. cound that be a problem? Here is what I triedWinWaitActive("[TITLE:Adobe Audition; CLASS:Audition v3.0]") ControlSend("[TITLE:Adobe Audition; CLASS:Audition v3.0]", "", "", "{F1}") Link to comment Share on other sites More sharing options...
provi Posted January 24, 2011 Author Share Posted January 24, 2011 Hehe, nice try, but nope, it's not Adobe Audition. And the different titles it's not a problem, tried with the full title and still does not work, and if I send a string, it will be printed in the window correctly. Seems to me that the string can be printed without directinput, but those special keys DO need the directinput.dll in order to work. Thanks guys for your help anyways Link to comment Share on other sites More sharing options...
provi Posted January 24, 2011 Author Share Posted January 24, 2011 I should add some relevant info: Send command didn't work in a 32 bit OS (it happened the same as it happens with ControlSend, you can send strings but not directinput buttons) but it does work in a 64 bit OS (controlsend however doesnt work either). Quite puzzling. Sorry for the double post. 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