I'm trying to emulate the hotkey functionality in AHK with VB.Net. Basically, mirror it identically. I'm not entirely sure how to get started. I did get something basic operational, however, it's a far cry from AHK's awesome native functionality. This will be developed for windows.
Public Class Form1
Private Declare Function GetKeyPress Lib "user32" Alias "GetAsyncKeyState" (ByVal key As Integer) As Integer
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Timer1.Enabled = True
Timer1.Interval = 1
Private Sub Timer1_Tick(ByVal Sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
If GetKeyPress(Keys.A) And GetKeyPress(Keys.Enter) Then
MsgBox("A And Enter Pressed")
Currently, this only works when I press all the keys together (pressed at once). How can I make it work by pressing the last key in the sequence to kick off the hotkey. Additionally, how would I add termination keys, like 'Enter' and 'Space' that kick off the hotkey.
Looking for a nudge, or an example to get started.