Skip to content

Instantly share code, notes, and snippets.

@supermarsx
Created February 3, 2024 23:59
Show Gist options
  • Save supermarsx/7fbf6936a1581120f4760962c919ff30 to your computer and use it in GitHub Desktop.
Save supermarsx/7fbf6936a1581120f4760962c919ff30 to your computer and use it in GitHub Desktop.
Press key repeatedly through hotkey
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_UseX64=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.14.3
Author: myName
Script Function:
Template AutoIt script.
#ce ----------------------------------------------------------------------------
; Script Start - Add your code below here
#include <MsgBoxConstants.au3>
; Press Esc to terminate script, Pause/Break to "pause"
Global $g_bPaused = False
HotKeySet("^+2", "Key") ; Shift-Alt-d
While 1
Sleep(100)
WEnd
Func TogglePause()
$g_bPaused = Not $g_bPaused
While $g_bPaused
Sleep(100)
ToolTip('Script is "Paused"', 0, 0)
WEnd
ToolTip("")
EndFunc ;==>TogglePause
Func Terminate()
Exit
EndFunc ;==>Terminate
Func Key()
Send("@",1)
EndFunc ;==>ShowMessage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment