Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 14:41

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Sending Keystrokes to background-window

Discussion on Sending Keystrokes to background-window within the AutoIt forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Apr 2014
Posts: 4
Received Thanks: 0
Question Sending Keystrokes to background-window

Hi,

i'm trying to build a simple bot for aura kingdom, that is able to send keystrokes, but i'm lacking in Auto-it and general programming-skills.

I've tried the ControlSend-command but thats just sending Strings not keystrokes.

I've tried the Send-command, but that just works if the game is in focus.

Any help or useful hint would be nice.

TIA flatter
flatter83 is offline  
Old 04/10/2014, 20:47   #2
 
alpines's Avatar
 
elite*gold: 60
Join Date: Aug 2009
Posts: 2,256
Received Thanks: 815
Did you try to send "{w}" instead of "w"? Because "{w}" are keystrokes and "w" is a string.
alpines is offline  
Old 04/10/2014, 21:01   #3
 
elite*gold: 0
Join Date: Apr 2014
Posts: 4
Received Thanks: 0
tried that already. the result is that it sends keystrokes, but they don't activate any skill of my char, but when i have the ingame chat in focus, the numbers are shown.

Code:
Local $hWnd = WinGetHandle("Aura Kingdom Online")
ControlSend ( $hWnd, "", "", "{6}")
flatter83 is offline  
Old 04/10/2014, 21:32   #4
 
alpines's Avatar
 
elite*gold: 60
Join Date: Aug 2009
Posts: 2,256
Received Thanks: 815
Why don't you hold down the key (I think "{6 down}" ?) and release it with "{6 up}" after a half second. It can work - but maybe it won't.
alpines is offline  
Old 04/10/2014, 22:50   #5
 
elite*gold: 0
Join Date: Apr 2014
Posts: 4
Received Thanks: 0
that was one thing i thaught of too, so i added
Code:
Opt("SendKeyDownDelay", 500)
it's still the same.
flatter83 is offline  
Old 04/10/2014, 23:01   #6
 
alpines's Avatar
 
elite*gold: 60
Join Date: Aug 2009
Posts: 2,256
Received Thanks: 815
Try to do it via SendMessage / PostMessage, it looks difficult for the first time but it'll probably fix your problem.
alpines is offline  
Old 04/10/2014, 23:28   #7
 
elite*gold: 0
Join Date: Apr 2014
Posts: 4
Received Thanks: 0
that was my next step.

right now im downloading a program to readout the parameters that are sent while pressing a key to get to know what i need to fill in.

pls correct me if that way probably isn't going work
flatter83 is offline  
Reply


Similar Threads Similar Threads
sending commands to window...
07/05/2013 - Kal Online - 0 Replies
oké i'm trying to run 2x autopicker simultaneously, yet I can only do this by sending "space" replica's. Which means i need to have 1 window on top. Anyway to send those commands to a specific window instead of my computer in general? Is that detectable? kind regards
Function not sending keystrokes
01/18/2012 - C/C++ - 2 Replies
Dear readers, Probably a lot of fails in the coding but nevermind that please. I am still learning it. At the moment I made a simple GUI with just one function. Repeat a text someone shouted. It will send 3 keystrokes each loop. 1. Spacebar 2. Arrow up 3. Enter key
Help with Postmessage, Sending keystrokes.. !
04/12/2011 - AutoIt - 6 Replies
Hello everyone , i use this sourcecode that i found for sending keys on a minimized window. ; #FUNCTION# ================================================== ================================================== ================ ; Name...........: SimulKey ; Description ...: Simulate a Key-Send to a specified handle in the Background ; Author ........: Felix Lehmann ; Modified.......: If you modify this Script, please enter your name here ; Remarks .......: - ; Related .......: - ; Parameters...
Aion 1.9.0.3 sending keystrokes in background mode
08/29/2010 - Aion - 1 Replies
Hello to all! I'am trying to send keystrokes in BACKGROUND MODE to AION client using C++ (Builder2009): I do it like that: ... PostMessage(Window,WM_KEYDOWN, VK_OEM_MINUS, 0x00020001); ... This function works good for me, but as i can see i can't send WASD or VK_MENU(ALT) and more, something like game protection
How can i send keystrokes to an application in background
04/09/2008 - Archlord - 3 Replies
i need something like a macro that can send keystrokes to an application in background and loop the sending in delay of 2 minutes or something... Any1 have an idea how can i do this or where can i download such program?



All times are GMT +1. The time now is 14:44.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.