Sign in to follow this  
Followers 0
IDontKnowWhatImDoing

How to make it Auto-Click

18 posts in this topic

I just want a simple macro that will auto double-click every 5 minutes or so. How would I do this? I have no idea what I'm doing. Any help would be greatly appreciated.

Share this post


Link to post
Share on other sites



Start by reading the helpfile then look for the word While / MouseClick


Start here if you are new Valuater's AutoIT 1-2-3Looking for an UDF - Look hereDo you need to do it twice - Autoit

Share this post


Link to post
Share on other sites

alright so thus far i have this:

While <0>

statements

MouseClick ( "left" [, x, y [, 2 [, 1 ]]] )

WEnd

so it will loop forever (I think...) but how do i make it wait for 5 minutes then do it again?

Share this post


Link to post
Share on other sites

alright so thus far i have this:

While <0>

statements

MouseClick ( "left" [, x, y [, 2 [, 1 ]]] )

WEnd

so it will loop forever (I think...) but how do i make it wait for 5 minutes then do it again?

Add Sleep(300000) to the loop. It will sleep for 300 seconds.

Roses are FF0000, violets are 0000FF... All my base are belong to you.

Share this post


Link to post
Share on other sites

While <0>

statements

MouseClick ( "left" [, x, y [, 2 [, 1 ]]] )

Sleep(300000)

WEnd

So that's my simple ever-lasting double-clicking macro? Or did I mess something up?

Share this post


Link to post
Share on other sites

While <0>

statements

MouseClick ( "left" [, x, y [, 2 [, 1 ]]] )

Sleep(300000)

WEnd

So that's my simple ever-lasting double-clicking macro? Or did I mess something up?

Guess you didn't test that? :whistle: Anyway, I guess you're ok, except for that you should write While 1 to keep it looping...

Roses are FF0000, violets are 0000FF... All my base are belong to you.

Share this post


Link to post
Share on other sites

Guess you didn't test that? :whistle: Anyway, I guess you're ok, except for that you should write While 1 to keep it looping...

heh yeah I'd much rather ask if it was ok rather than test it and jam my computer. Thanks a lot!

Share this post


Link to post
Share on other sites

I say better jam my computer than ask :whistle:


Start here if you are new Valuater's AutoIT 1-2-3Looking for an UDF - Look hereDo you need to do it twice - Autoit

Share this post


Link to post
Share on other sites

Well for my code it says error..

MouseClick("left"[,x,y[,2[,1]]])

MouseClick("left"^ERROR

so mine doesn't work. but the one that sheville posted did work. How would I figure out the numbers for where the mouse would be or do I just mess around with it and does the one that sheville posted double-click?

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

Well for my code it says error..

MouseClick("left"[,x,y[,2[,1]]])

MouseClick("left"^ERROR

so mine doesn't work. but the one that sheville posted did work. How would I figure out the numbers for where the mouse would be or do I just mess around with it and does the one that sheville posted double-click?

Open AutoIt Window Info, it should be in Start->Programs->Autoit-> AutoIt Window info.

Move the mouse on the spot it should double-click and look in the Window Info at

>>>>>>Mouse Details<<<<<<

Scree: X: Y:

You should then replace the 100,100 in Shevilie's script with the numbers shown.

If you have bother to read the 2 pages help on Mouse Click there is an example.

; Double click at 0,500  <---- These are the coordinates you need to adjust
MouseClick("left", 0, 500, 2)
Edited by Chupa

Share this post


Link to post
Share on other sites

you just need to replace the X,Y with real coordinates, those are just examples, and also remove the brackets, I don't know weather or not they affect it at all but minds well....


[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

Share this post


Link to post
Share on other sites

This is getting weird.

Please Chupa, do some autoit tutorials, they can be found here in the forum and in the AutoIt help files. Also, please check the code examples in the help file.

About the brackets: the brackets are part of the syntax description; they are NOT to be used in actual code. Some parameter sitting between brackets in the syntax description means it's optional, meaning you can choose to indicate it or not.

Also, please test your code and try to get it right yourself instead of asking other people to do it for you. If you get stuck somewhere, people here WILL try to help you or even correct your code for you, but please show more effort if you want more help. Everyone here has f***ed up some scripts, that's part of learning.


Roses are FF0000, violets are 0000FF... All my base are belong to you.

Share this post


Link to post
Share on other sites

This is getting weird.

Please Chupa, do some autoit tutorials, they can be found here in the forum and in the AutoIt help files. Also, please check the code examples in the help file.

HUH? I Gave examples from the help file. I'm not the one asking how to doubleclick, DontKnowWhatImDoing is! :whistle:

Share this post


Link to post
Share on other sites

heh yeah I'd much rather ask if it was ok rather than test it and jam my computer. Thanks a lot!

Ron!!!...???

....Is that you again???

8)


NEWHeader1.png

Share this post


Link to post
Share on other sites

lol what? Who's Ron?

Share this post


Link to post
Share on other sites
:whistle: I suppose its a joke from somewhere....

[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

Share this post


Link to post
Share on other sites

HUH? I Gave examples from the help file. I'm not the one asking how to doubleclick, DontKnowWhatImDoing is! :whistle:

Heheh :"> Sorry! I stand corrected. Please accept my sincere apologies?


Roses are FF0000, violets are 0000FF... All my base are belong to you.

Share this post


Link to post
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
Sign in to follow this  
Followers 0