Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   Visual Basic (http://www.programmingforums.org/forum18.html)
-   -   Auto Clicker: Need help (http://www.programmingforums.org/showthread.php?t=6731)

Pissi Oct 30th, 2005 1:20 PM

Auto Clicker: Need help
 
Hey im trying to make an autoclicker and its going to be in the same form as an autotyper though i cannot get it to work. Rory has tried to help me and its properbly just a mistake i am making.
Can someone help me make a quick autoclicker where you can set how many left mouse clicks it does per second? It would realy help, thanks.

13EN Nov 26th, 2005 11:55 AM

hi i cannot help with the auto clicker program but i have 2 questions: Are you using them for Runescape? also Please can you tell me how to make an auto talker because all of my attempts have failed miserably!!

Dameon Nov 26th, 2005 11:59 AM

Perhaps you should...I don't know...post some details? Such as code?

ivan Nov 26th, 2005 1:37 PM

Can somebody explain to me why so many people are trying to code autoclikers? For what are they used???

jayme Nov 26th, 2005 2:08 PM

im going to guess for google ads on their own site? something along the lines of making money from ads probably..

zero771 Nov 26th, 2005 3:49 PM

ooh runescape, i remember that game,
autoclickers repeatedly click in places you program it to click in

13EN Nov 26th, 2005 4:07 PM

ok then this is the most recent attempt:


:

Private Sub Command1_Click()
Timer1.Interval = 100
Timer1.Enabled = True
End Sub

Private Sub Command2_Click()
Timer1.Enabled = False
End Sub

Private Sub Timer1_Timer()
Timer1.Interval = 5000
SendKeys Text1.Text
SendKeys "{enter}"
End Sub


i got help with that off another forum

Rory Nov 27th, 2005 8:31 AM

You want to use the mouse_event and keyb_event APIs, they are implemented at the driver level, so will work if the application is using DirectInput or event hooks, which SendKeys won't work for (as it's a wrapper for SendMessage WM_KEYUP I believe), especially if this is for a game.

Pissi Dec 5th, 2005 3:13 PM

Hey, i did it, and that code you found on a forum is right for the auto talker, they are simple to make, but the clicker..

Put this in as a new module:
:

Public Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)
Public Declare Function SetCursorPos Lib "user32" (ByVal X As Long, ByVal Y As Long) As Long

    Public Const MOUSEEVENTF_LEFTDOWN = &H2
    Public Const MOUSEEVENTF_LEFTUP = &H4
    Public Const MOUSEEVENTF_MIDDLEDOWN = &H20
    Public Const MOUSEEVENTF_MIDDLEUP = &H40
    Public Const MOUSEEVENTF_RIGHTDOWN = &H8
    Public Const MOUSEEVENTF_RIGHTUP = &H10
    Public Const MOUSEEVENTF_MOVE = &H1


Then make a timer and add this code:

:

Private Sub Timer1_Timer()
mouse_event MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0
mouse_event MOUSEEVENTF_LEFTUP, 0, 0, 0, 0
End Sub


Then just add buttons start and stop and set each one of them to enable/disable the clicker, and also you could add a text box to define the interval of the clicks:

:

Private Sub Command1_Click()
Timer1.Interval = Text1.Text
Timer1.Enabled = True
End Sub

Private Sub Command2_Click()
Timer1.Interval = Text1.Text
Timer1.Enabled = False
End Sub




hmm...i swear i have made more posts than 2! :P

coldDeath Dec 5th, 2005 3:47 PM

Hehe posts in "the lounge" don't count ;-)


All times are GMT -5. The time now is 4:17 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC