Jump to content

Recommended Posts

Posted

I am still newb to this and you guys have more then helped me in the past but maybe i can get your help again.

What i need is a script that when i press the left mouse key it would prest then Left + right then wait a split second and press the right button again....

Can this be done?

Posted

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
MouseClick("Right)"
EndIf
WEnd

this will

you : left click

it: left click > right click > right click

NOTE: requires beta!

~cdkid

AutoIt Console written in C#. Write au3 code right at the console :D_FileWriteToLineWrite to a specific line in a file.My UDF Libraries: MySQL UDF Library version 1.6 MySQL Database UDF's for AutoItI have stopped updating the MySQL thread above, all future updates will be on my SVN. The svn location is:kan2.sytes.net/publicsvn/mysqlnote: This will still be available, but due to my new job, and school hours, am no longer developing this udf.My business: www.hirethebrain.com Hire The Brain HireTheBrain.com Computer Consulting, Design, Assembly and RepairOh no! I've commited Scriptocide!
Posted (edited)

more like :o

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right)"
EndIf
WEnd
Edited by thatsgreat2345
  • Moderators
Posted

more like :o

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right)"
EndIf
WEnd
MouseClick("Right)"? Or MouseClick("Right")? :geek:

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted (edited)

cunfuzled i dont see the differnt :o

Could i add a

HotKeySet("^!z","Movment");^!z is Ctrl+Alt+'z' to run the Movment
HotKeySet("^!x","End");^!x is Ctrl+Alt+'x' to close the Movment
Func Movment()
#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right)"
EndIf
WEnd
Func End()

I think i screwed that up royaly... but i tried.

Edited by King
  • Moderators
Posted (edited)

cunfuzled i dont see the differnt :o

Everyone keeps doing it...

MousClick("Right)" Is the incorrect syntax

MouseClick("Right") Is the correct syntax

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted (edited)

I am useing

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right")
EndIf
WEnd

I get Error: Unable to Parse line.

I downloaded http://www.autoitscript.com/cgi-bin/getfil...it-v3-setup.exe to use it right?

Ok i changed the ("right") and now i am getting

Error: Unknown Function Name

Edited by King
Posted (edited)

I am useing

#include <Misc.au3>

While 1

sleep(100)

If _IsPressed('01') Then

MouseClick("left")

MouseClick("Right")

sleep(a split second)

MouseClick("Right)"

EndIf

WEnd

I get Error: Unable to Parse line.

I downloaded http://www.autoitscript.com/cgi-bin/getfil...it-v3-setup.exe to use it right?

the error is in red... try this... and you were helped by a newbie!

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right")
EndIf
WEnd

If that works... well then, I did something good today

Edited by oakchas
Posted

change your code to this

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right")
EndIf
WEnd

sorry for the type-o :o

AutoIt Console written in C#. Write au3 code right at the console :D_FileWriteToLineWrite to a specific line in a file.My UDF Libraries: MySQL UDF Library version 1.6 MySQL Database UDF's for AutoItI have stopped updating the MySQL thread above, all future updates will be on my SVN. The svn location is:kan2.sytes.net/publicsvn/mysqlnote: This will still be available, but due to my new job, and school hours, am no longer developing this udf.My business: www.hirethebrain.com Hire The Brain HireTheBrain.com Computer Consulting, Design, Assembly and RepairOh no! I've commited Scriptocide!
Posted (edited)

edit:

oh hahaha didnt even notice the Sleep(a split second) :o

Edited by cdkid
AutoIt Console written in C#. Write au3 code right at the console :D_FileWriteToLineWrite to a specific line in a file.My UDF Libraries: MySQL UDF Library version 1.6 MySQL Database UDF's for AutoItI have stopped updating the MySQL thread above, all future updates will be on my SVN. The svn location is:kan2.sytes.net/publicsvn/mysqlnote: This will still be available, but due to my new job, and school hours, am no longer developing this udf.My business: www.hirethebrain.com Hire The Brain HireTheBrain.com Computer Consulting, Design, Assembly and RepairOh no! I've commited Scriptocide!
Posted (edited)

New error. Error: Unknow Function Name

Then try this:

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
;sleep(a split second)
MouseClick("Right")
EndIf
WEnd
Edited by oakchas
Posted

How do i know if i am useing the beta. this is what i am doing

First You will need to DL

http://www.autoitscript.com/cgi-bin/getfil...it-v3-setup.exe

Second - Create a note pad file and add this code to it.

#include <Misc.au3>
While 1
sleep(100)
If _IsPressed('01') Then
MouseClick("left")
MouseClick("Right")
sleep(a split second)
MouseClick("Right")
EndIf
WEnd

Third - Save the file as anythingyouwish.au3

Fourth - Open the autoit program and browse for this file. Select the file and at the bottom there will be a button that say "Convert". convert the file.

Fith - Run the new converted file. It will appear in the bottom right corner of your screen next to your time.

Posted

To get to the program i am opening the folder, going to the aut2exe folder then clicking on the aut2exe.exe

Posted

Line 0 (File "C:\DandS\C\Mouse.exe"):

If _ispressed('01') Then

If ^ ERROR

Error: Unknown Function Name

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
×
×
  • Create New...