|  |  | 
|  | 
|  | 
|  Andreas
 Miethe
 
 
  | | KompilierenMarkierenSeparieren
 '#################################
'Hotkey-Control
'Andreas Miethe
'2012
'#################################
Def SetHotKey(3)   SendMessage(&(1),1025,MakeWord(%(2),%(3)),0)
Def GetHotKey(1)   SendMessage(&(1),1026,0,0)
Def GetKey(1)      LoWord(Lobyte(SendMessage(&(1),1026,0,0)))
Def GetModifyer(1) LoWord(Hibyte(SendMessage(hk&,1026,0,0)))
Proc HiByte
    Parameters word%
    Return word% >> 8
EndProc
Proc LoByte
    Parameters word%
    Return word% & $FF
EndProc
Proc MakeWord
    Parameters lbyte%, hbyte%
    Return (lbyte% & $FF) | ((hbyte% & $FF) << 8)
EndProc
WindowTitle "Tastenkombinationionen"
Cls
Var hk& = Control("msctls_hotkey32","",$54010200,300,10,250,24,%hwnd,2000,%hinstance)
SetHotKey(hk&,65,4)' ALT + A setzen
While 1
    SetFocus(hk&)
    WaitInput
    Cls
    Print "Du hast eingegeben:          "
    Print
    Print "Taste     ", GetKey(hk&)
    Print "Modifyer  ", GetModifyer(hk&)
EndWhile
 | 
 | 
|  | 
|  | | Gruss Andreas ________ ________ ________ ________ _ Profan 3.3 - XProfanX2 Win 95,98,ME,2000,XP,Vista - Win 7 32 / 64 Bit ASUS X93S - Intel Core I7-NVIDIA GForce 540M 8GB Arbeitsspeicher Homepage :  [...]  | 07.10.2012  ▲ | 
 | 
|  | 
| 
 
 
 |