Jump to content

Auto click on keyboard combination


Recommended Posts

hello all,

I'm new and just wanted to ask my question before putting time into AutoIt.

All i want to do, is upon a certain keyboard combination (let's say ctrl+shift+F1), i want my mouse to start auto clicking at every lets says 5 seconds.

Would i have to code such and app or could AutoIt do it straight from the box ?

Thanks all

Lespoils

Link to comment
Share on other sites

This is copied directly from the helpfile under Hotkeyset... hotkeyset will run a function when that key or key combo is pressed. So here pressing shift+alt+d will run function ShowMessage.

; Press Esc to terminate script, Pause/Break to "pause"

Global $Paused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("{ESC}", "Terminate")
HotKeySet("+!d", "ShowMessage")  ;Shift-Alt-d

;;;; Body of program would go here ;;;;
While 1
    Sleep(100)
WEnd
;;;;;;;;

Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        sleep(100)
        ToolTip('Script is "Paused"',0,0)
    WEnd
    ToolTip("")
EndFunc

Func Terminate()
    Exit 0
EndFunc

Func ShowMessage()
    MsgBox(4096,"","This is a message.")
EndFunc

Welcome to the forum by the way. I wasn't paying attention to you saying you haven't yet put the time into autoit so I sorta over answered your question. But anyway doing what you want to is definitely achievable.

Edited by someone
While ProcessExists('Andrews bad day.exe')
	BlockInput(1)
	SoundPlay('Music.wav')
	SoundSetWaveVolume('Louder')
WEnd
Link to comment
Share on other sites

hello all,

I'm new and just wanted to ask my question before putting time into AutoIt.

All i want to do, is upon a certain keyboard combination (let's say ctrl+shift+F1), i want my mouse to start auto clicking at every lets says 5 seconds.

Would i have to code such and app or could AutoIt do it straight from the box ?

Thanks all

Lespoils

http://www.autoitscript.com/forum/index.php?showtopic=45332

www.itoady.com

A* (A-star) Searching Algorithm - A.I. Artificial Intelligence bot path finding

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...