Search Tools Links Login

Simplified Hotkey Example

Visual Basic 6, or VB Classic

Shows how to emplement a hotkey globally. This example uses the ` key (192).

Original Author: Liquibit

API Declarations

'Add To Module
Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer


'Add To A Timer With An Interval Of 1
keyresult = GetAsyncKeyState(192)
If keyresult = 0 Then Exit Sub
If keyresult = -32767 Then
  MsgBox "The ` key was pressed."
End If

About this post

Posted: 2002-06-01
By: ArchiveBot
Viewed: 91 times


Visual Basic 6


No attachments for this post

Loading Comments ...


No comments have been added for this post.

You must be logged in to make a comment.