Hallo liebe com,
ich hab folgendes problem und dabei konnte mir die suche leider nicht so helfen.
Ich programmiere derzeit ein Tool, das im hintergrund mitläuft. Ingame simuliere ich dann die F12 taste alle 5 minuten. Das funktioniert auch wunderbar.
Das Problem was ich nun zurzeit habe ist, das ingame zugleich mehrere tasten gedrückt werden, womit dann das tool "warscheinlich" mit dem erzwungenen Tastendruck (f12) probleme bekommt und nicht F12 simulieren kann.
Gibt es nun eine Möglichkeit, wenn das tool die F12 taste imuliert, das es eine höhere priorität hat als die normalen tastatureingaben der tastatur?
Hier der Code (dieser funktioniert soweit)
|
Visual Basic Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
<DllImport("user32.dll", CallingConvention:=CallingConvention.StdCall, _
CharSet:=CharSet.Unicode, EntryPoint:="keybd_event", _
ExactSpelling:=True, SetLastError:=True)> _
Public Shared Function keybd_event(ByVal bVk As Int32, ByVal bScan As Int32, _
ByVal dwFlags As Int32, ByVal dwExtraInfo As Int32) As Boolean
End Function
Private Sub imulation()
Try
Const VK_F12 As Byte = &H7B
keybd_event(VK_F12, 0, 0, 0)
Catch
End Try
End Sub
|
mfg
djmatrix