 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
Darkfaller Guest
|
Posted: Thu Aug 06, 2009 1:01 am Post subject: Darkfall Online Question.. |
|
|
.. Hi there,
I know, there are 3-4 Posts here about that, but they didnt help me alot..
im a complete noob in such things, my first script, and then its a bigone :/
All i need is to send the key "H" to a window called "Darfkall Online" even when the window isnt active (minimized or not, dont matter)
what i tryed out so far is:
| Code: | Numpad1::
SetTitleMatchMode, 2
PostMessage, 0x111, Darkfall Online, H |
Where i get the code was:
http://www.autohotkey.com/docs/misc/SendMessage.htm
But i dont get it, 0x111 should stand for a wm_command.. but i dont know what that is..
so im lost at the very first word of the code :/
hopefully someone can help me out here!
thx a lot! |
|
| Back to top |
|
 |
lilalurl.T32
Joined: 17 May 2007 Posts: 391 Location: Titan
|
Posted: Thu Aug 06, 2009 1:58 am Post subject: |
|
|
I believe you'd better try using the ControlSend command rather than Post/Sendmessage.
________
MERCEDES-BENZ 190 SPECIFICATIONS
Last edited by lilalurl.T32 on Sun Mar 13, 2011 6:43 am; edited 1 time in total |
|
| Back to top |
|
 |
Guest
|
Posted: Thu Aug 06, 2009 8:22 pm Post subject: |
|
|
| With ControlSend, i can send to an inactive window too? |
|
| Back to top |
|
 |
jethrow
Joined: 24 May 2009 Posts: 1907 Location: Iowa, USA
|
|
| Back to top |
|
 |
Darkfaller Guest
|
Posted: Fri Aug 07, 2009 1:21 am Post subject: |
|
|
Ok, this shows me how to put the menus and stuff in..
but all i want is to send a simple letter (hotkey in the game) to the game..
nothing more, i just dont get it..
Winspy wount show me any messages when i press "H".. |
|
| Back to top |
|
 |
lilalurl.T32
Joined: 17 May 2007 Posts: 391 Location: Titan
|
Posted: Fri Aug 07, 2009 5:35 am Post subject: |
|
|
It seems you are taking the terms "PostMessage" literally, as in "chat" message, while what PostMessage actually does is posting a "computer" message.
What you want to do is Send a simulated keystroke. Therefore, have a look at Send and ControlSend (which can send to an inactive window).
________
Uggs
Last edited by lilalurl.T32 on Sun Mar 13, 2011 6:44 am; edited 1 time in total |
|
| Back to top |
|
 |
Darkfaller Guest
|
Posted: Fri Aug 07, 2009 7:38 pm Post subject: |
|
|
Ok, thx for the Infos..
Now it seems, i cant send to Darkfall Online a key.. it just wont work..
my code is this:
| Code: |
NumPad1::
SetTitleMatchMode, 2
ControlSend,, m, ahk_id SFMainWindow ;tryied this
ControlSend,, m, Darkfall Online ; tryied this aswell.. wont work..
|
Dont know why it wont work, maybe the game is made that it wont work? |
|
| Back to top |
|
 |
jethrow
Joined: 24 May 2009 Posts: 1907 Location: Iowa, USA
|
Posted: Sat Aug 08, 2009 6:26 am Post subject: |
|
|
If using IE, this should work: | Code: | NumPad1::
DetectHiddenWindows, On ; allow sending to a minimized window
SetTitleMatchMode, 2
ControlSend, Internet Explorer_Server1, m, Darkfall
Return |
_________________
- in case I forgot to smile
Basic Webpage Controls
COM Object Reference |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|