Skip to content
MPGHThe Dark Arts
/
RegisterLog in
Forum
Community
What's NewLatest posts across the boardTrendingHottest threads right nowSubscribedThreads you follow
Discussion
GeneralIntroductionsEntertainmentDebate FortFlaming & Rage
Board
News & AnnouncementsMPGH TimesSuggestions & HelpGiveaways
More Sections
Art & Graphic DesignProgrammingHackingCryptocurrency
Hacks & Cheats
Games
ValorantCS2 / CS:GOCall of Duty / WarzoneFortniteApex LegendsEscape From Tarkov
+14 moreLeague of LegendsGTA VMinecraftRustROTMGBattlefieldTroveBattleOnCombat ArmsCrossFireBlackshotRuneScapeDayZDead by Daylight
Resources
Game Hacking TutorialsReverse EngineeringGeneral Game HackingAnti-CheatConsole Game Hacking
Tools
Game Hacking ToolsTrainers & CheatsHack/Release NewsNew
Submit a release →Share your cheat, tool, or config with the community.
AINEW
AI Tools
General & DiscussionPrompt EngineeringLLM JailbreaksHotAI Agents & AutomationLocal / Open Models
AI × Gaming
AI Aimbots & VisionML Anti-CheatGame Bots & Automation
Create
AI Coding / Vibe CodingAI Art & MediaAI Voice & TTS
The AI frontier →Where game hacking meets modern machine learning. Jump in.
Marketplace
Buy & Sell
SellingBuyingTradingUser Services
Trust & Safety
Middleman LoungeMarketplace TalkVouch Copy Profiles
Money
Cryptocurrency TalkCurrency ExchangeWork & Job Offers
Start selling →List accounts, services, and goods. Use the middleman to trade safe.
MPGH The Dark Arts

A community for offensive security research, reverse engineering, and AI.

Community

ForumMarketplaceSearch

Account

RegisterLog in

Legal

Privacy PolicyForum RulesHelp & FAQ
© 2026 MPGH · All rights reserved.Built by the community, for the community. For educational purposes onlyContent is shared for security research and education — we don't condone illegal use. You're responsible for complying with applicable laws. Use at your own risk.
Home › Forum › Programming › Visual Basic Programming › [HELP] Hotkeys

[HELP] Hotkeys

Posts 1–14 of 14 · Page 1 of 1
Spookerzz
Spookerzz
[HELP] Hotkeys
What I would like this code to do is to when I press "F6" Say what is in "Textbox.1" and When I press "F7" it stops

Code:
Imports System.Text
Public Class Form1
    Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vkey As Long) As Integer
    Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
        Form2.Show()
    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load



    End Sub

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick

    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        If GetAsyncKeyState(Keys.F6) Then
            Timer1.Enabled = True
            SendKeys.Send(TextBox1.Text)
            SendKeys.Send("{Enter}")
        End If

    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        If GetAsyncKeyState(Keys.F7) Then
            Timer1.Enabled = False

        End If
    End Sub
End Class
#1 · 16y ago
Blubb1337
Blubb1337
declare getasynckeystate

Code:
Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vkey As Long) As Integer
timer1_tick:

Code:
SendKeys.Send(TextBox1.Text)
            SendKeys.Send("{Enter}")
timer2_tick:

Code:
Dim f6 As Boolean
 Dim f7 As Boolean
     
        f6 = GetAsyncKeyState(Keys.F6)

        If f6 = True Then
            timer1.enabled = true
        End If

  f7 = GetAsyncKeyState(Keys.F7)

        If f7 = True Then
            timer1.enabled = false
        End If
-> ->

Code:
Public Class Form1

    Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vkey As Long) As Integer

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
        SendKeys.Send(TextBox1.Text)
        SendKeys.Send("{Enter}")
    End Sub

    Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
        Dim f6 As Boolean
        Dim f7 As Boolean

        f6 = GetAsyncKeyState(Keys.F6)

        If f6 = True Then
            Timer1.Enabled = True
        End If

        f7 = GetAsyncKeyState(Keys.F7)

        If f7 = True Then
            Timer1.Enabled = False
        End If
    End Sub
End Class
#2 · 16y ago
Spookerzz
Spookerzz
What does it do?

Its like an auto clicker?
#3 · 16y ago
Zoom
Zoom
It's a spammer with hotkeys, very simple.
#4 · 16y ago
Spookerzz
Spookerzz
But it starts off spamming and I can't press Stop or anything
#5 · 16y ago
Blubb1337
Blubb1337
hit f7 for stop?

I answered you question above...lol...
#6 · 16y ago
Spookerzz
Spookerzz
I do hit F7 Dosnt work
#7 · 16y ago
Zoom
Zoom
here's your problem:
[php]
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If GetAsyncKeyState(Keys.F6) Then
Timer1.Enabled = True
SendKeys.Send(TextBox1.Text)
SendKeys.Send("{Enter}")
End If

End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If GetAsyncKeyState(Keys.F7) Then
Timer1.Enabled = False

End If
End Sub[/php]
Add the hotkey code to a timer(interval=10)
#8 · 16y ago
Spookerzz
Spookerzz
*Sighs I'll try tomorrow it's 1:30 in the morning and I'm 12 =,=

Night everyone.
#9 · 16y ago
NextGen1
NextGen1
Explanation

[php]
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If GetAsyncKeyState(Keys.F6) Then
Timer1.Enabled = True
SendKeys.Send(TextBox1.Text)
SendKeys.Send("{Enter}")
End If

End Sub

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If GetAsyncKeyState(Keys.F7) Then
Timer1.Enabled = False

End If
End Sub
[/php]

The actual problem with this is it is in a button click event which means it will work if you are clicking the button and pressing the keys at the same time.

If the Button is being pressed and If f7 is being pressed, you want f7 to be checked always, Someone should make a module and make it easy for everyone
#10 · 16y ago
Spookerzz
Spookerzz
How would I do this?
#11 · 16y ago
Shark23
Shark23
Nextgen has said this before but you can put 2 timers in. Timer2 will be set to an interval of 1. Put the events for the hotkeys inside timer2 so they will be checked constantly.
#12 · 16y ago
Blubb1337
Blubb1337
An interval of 100 is fine tho. And I already posted such code in my post
#13 · 16y ago
ruskipotsan
ruskipotsan
Idk if someone said this already. But aren't you supposed to enable the Timer2 for this to work.
The code is perfect, but it didn't work for me until I enabled it.
#14 · 16y ago
Posts 1–14 of 14 · Page 1 of 1

Post a Reply

Similar Threads

  • [HELP] hotkey #$*/"$#)(*&?"By herowarz in Visual Basic Programming
    5Last post 18y ago
  • [HELP] HotKeysBy Zhhot in Visual Basic Programming
    3Last post 16y ago
  • [HELP]=HotkeysBy theavengerisback15 in Visual Basic Programming
    6Last post 16y ago
  • [HELP]Hotkeys[Solved]By luckie12 in Visual Basic Programming
    3Last post 16y ago
  • [HELP]Hotkeys[Solved]By dylan40 in Visual Basic Programming
    16Last post 16y ago

Tags for this Thread

None