[TuT]Very Basic Hotkeys

Posts 1–5 of 5 · Page 1 of 1
[TuT]Very Basic Hotkeys
This is Some VERY BASIC Hotkeys

Code:
Public Class Form1
    Protected Overrides Function ProcessDialogKey(ByVal keyData As System.Windows.Forms.Keys) As Boolean

        Select Case (keyData)
            Case Keys.F10
'Replace F10 with the hotkey you want.
'Code here.
            Case Keys.F11
'Replace F11 with the hotkey you want.
'Code here.
        End Select
        Return MyBase.ProcessDialogKey(keyData)
    End Function

Heres a Basic setup for HotKeys with a AutoTyper

Code:
Public Class Form1
    Protected Overrides Function ProcessDialogKey(ByVal keyData As System.Windows.Forms.Keys) As Boolean

        Select Case (keyData)
            Case Keys.F10
                Timer1.Start()
            Case Keys.F11
'When I tested this, the Timer1.Stop didnt work. But you can still try.
                Timer1.Stop()
        End Select
        Return MyBase.ProcessDialogKey(keyData)
    End Function
Why not just use MCLHotkey.ocx?
Quote Originally Posted by That0n3Guy View Post
Why not just use MCLHotkey.ocx?
I dont know what that is 
Wont both work the same way?
Why not just use GetASyncKeyState its way more simple than that(but thats my opinion)
Quote Originally Posted by Iamazn View Post
I dont know what that is 
Wont both work the same way?
No, the OCX file make's it a lot easier.

Add my attachment as a component, and use it like you would a timer, when you click it you'll see a property, VKey, set that to the key you want to use and then double click the item it added to your form and put your code there.
MCLHotkey.rarattachment deleted · 14 downloads before removal
Posts 1–5 of 5 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

Talk with us