|
|
Up |
|
|
  |
Author: NhocNhoc Date: May 11, 2008 16:11
I have try to use this:
AnsiString strWindowName = "Element Client";
HWND windowHandle = FindWindow(0, strWindowName.c_str());
if (windowHandle)
{
SendMessage(windowHandle, WM_SYSKEYDOWN,0x12,0x20380001);
SendMessage(windowHandle, WM_SYSKEYDOWN,0x33,0x20040001);
SendMessage(windowHandle, WM_SYSCHAR,0x33,0x20040001);
SendMessage(windowHandle, WM_KEYUP,0x12,0xc0380001);
SendMessage(windowHandle, WM_KEYUP,0x33,0xc0040001);
}
But nothing happen
If i hold ALT when that code run, i'll effect, i think maybe that code cant
force event ALT hold key down.
Can someone help me.
PS: I cant use Key_bd() because sometime i'll hide that application (not
active)
|
| |
|
| | 1 Comment |
|
  |
|
|
  |
Author: Christian ASTORChristian ASTOR Date: May 17, 2008 03:52
Nhoc wrote:
> I have try to use this:
>
> AnsiString strWindowName = "Element Client";
> HWND windowHandle = FindWindow(0, strWindowName.c_str());
> if (windowHandle)
> {
> SendMessage(windowHandle, WM_SYSKEYDOWN,0x12,0x20380001);
> SendMessage(windowHandle, WM_SYSKEYDOWN,0x33,0x20040001);
> SendMessage(windowHandle, WM_SYSCHAR,0x33,0x20040001);
> SendMessage(windowHandle, WM_KEYUP,0x12,0xc0380001);
> SendMessage(windowHandle, WM_KEYUP,0x33,0xc0040001);
> }
>
> But nothing happen
>
> If i hold ALT when that code run, i'll effect, i think maybe that code cant
> force event ALT hold key down.
>
> Can someone help me. ...
|
| Show full article (0.91Kb) |
|
| | no comments |
|
RELATED THREADS |
  |
|
|
|
|
|