King Posted March 7, 2006 Share Posted March 7, 2006 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? Link to comment Share on other sites More sharing options...
cdkid Posted March 7, 2006 Share Posted March 7, 2006 #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! Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted March 7, 2006 Share Posted March 7, 2006 (edited) more like #include <Misc.au3> While 1 sleep(100) If _IsPressed('01') Then MouseClick("left") MouseClick("Right") sleep(a split second) MouseClick("Right)" EndIf WEnd Edited March 7, 2006 by thatsgreat2345 Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted March 7, 2006 Moderators Share Posted March 7, 2006 more like #include <Misc.au3> While 1 sleep(100) If _IsPressed('01') Then MouseClick("left") MouseClick("Right") sleep(a split second) MouseClick("Right)" EndIf WEndMouseClick("Right)"? Or MouseClick("Right")? 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. Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted March 7, 2006 Share Posted March 7, 2006 MouseClick("Right)"? Or MouseClick("Right")? cunfuzled i dont see the differnt Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 (edited) cunfuzled i dont see the differnt 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 March 7, 2006 by King Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted March 7, 2006 Moderators Share Posted March 7, 2006 (edited) cunfuzled i dont see the differnt Everyone keeps doing it...MousClick("Right)" Is the incorrect syntaxMouseClick("Right") Is the correct syntax Edited March 7, 2006 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. Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted March 7, 2006 Share Posted March 7, 2006 hahahah i didnt even notice that but not my fault just copied cdkid Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 (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 WEndI 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 March 7, 2006 by King Link to comment Share on other sites More sharing options...
oakchas Posted March 7, 2006 Share Posted March 7, 2006 (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 March 7, 2006 by oakchas Link to comment Share on other sites More sharing options...
cdkid Posted March 7, 2006 Share Posted March 7, 2006 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 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! Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 New error. Error: Unknow Function Name Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted March 7, 2006 Share Posted March 7, 2006 hahahahah u probaly didnt change the sleep #include <Misc.au3> While 1 sleep(100) If _IsPressed('01') Then MouseClick("left") MouseClick("Right") sleep(500) MouseClick("Right") EndIf WEnd Link to comment Share on other sites More sharing options...
cdkid Posted March 7, 2006 Share Posted March 7, 2006 (edited) edit: oh hahaha didnt even notice the Sleep(a split second) Edited March 7, 2006 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! Link to comment Share on other sites More sharing options...
oakchas Posted March 7, 2006 Share Posted March 7, 2006 (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 March 7, 2006 by oakchas Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 How do i know if i am useing the beta. this is what i am doingFirst You will need to DLhttp://www.autoitscript.com/cgi-bin/getfil...it-v3-setup.exeSecond - 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 WEndThird - Save the file as anythingyouwish.au3Fourth - 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. Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 To get to the program i am opening the folder, going to the aut2exe folder then clicking on the aut2exe.exe Link to comment Share on other sites More sharing options...
oakchas Posted March 7, 2006 Share Posted March 7, 2006 slow down king,,, do you really want to make an executable file? first get the script working right in autoit. Link to comment Share on other sites More sharing options...
King Posted March 7, 2006 Author Share Posted March 7, 2006 Line 0 (File "C:\DandS\C\Mouse.exe"): If _ispressed('01') Then If ^ ERROR Error: Unknown Function Name Link to comment Share on other sites More sharing options...
Thatsgreat2345 Posted March 7, 2006 Share Posted March 7, 2006 probaly because you dont have beta or you didnt inlucde misc.au3 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now