Ra8er 0 Posted July 14, 2010 (edited) Farm() Func Farm() If WinExists("World of Warcraft") Then $hWnd = WinGetHandle("World of Warcraft") ElseIf Exit EndIf Sleep(200) $Maden = 1 While $Maden <= 100 ControlSend($hWnd, "", "", "{G}"); $Maden = $Maden + 1 ControlSend($hWnd, "", "", "{TAB}") Sleep(6000) ControlClick( "World of Warcraft", "", 0 [, "right" [, 1 [, 1940 [, 470 ]]]] ) Sleep(7000) ControlClick( "World of Warcraft", "", 0 [, "right" [, 1 [, 1940 [, 470 ]]]] ) ControlClick( Sleep(1000) Wend EndFunc I Want the Script to double rightclick with a delay of 7 seconds, but i get an error when the script reaches the controlclick line. I cant find the Mistake, can anyone please help me? The error is a Parssing error, may this helps Greetings Ra8er Edited July 14, 2010 by Ra8er Share this post Link to post Share on other sites
PsaltyDS 39 Posted July 14, 2010 (edited) Read the sticky at the top of the forum, then drop the topic. Edited July 14, 2010 by PsaltyDS Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Share this post Link to post Share on other sites
Ra8er 0 Posted July 14, 2010 Im playing on a Privat server, so i am not bound to the EULA. Share this post Link to post Share on other sites
TheLaughingMan 2 Posted July 14, 2010 Remove all the brackets. Remove ElseIf and Exit Remove unfinished ControlClick Place the EndIf before EndFunc Make sure you have a correct controlID Add quotation marks on the controlID ControlClick("Untitled - Notepad", "", "Edit1", "left", 1, 0, 0) Share this post Link to post Share on other sites
Ra8er 0 Posted July 15, 2010 Remove all the brackets. Remove ElseIf and Exit Remove unfinished ControlClick Place the EndIf before EndFunc Make sure you have a correct controlID Add quotation marks on the controlID ControlClick("Untitled - Notepad", "", "Edit1", "left", 1, 0, 0) Farm() Func Farm() If WinExists("World of Warcraft") Then $hWnd = WinGetHandle("World of Warcraft") Sleep(200) $Maden = 1 While $Maden <= 100 ControlSend($hWnd, "", "", "{G}") $Maden = $Maden + 1 Sleep(6000) ControlSend($hWnd, "", "", "{TAB}") Sleep(500) ControlClick( "World of Warcraft", "", 0 , "right", 1, 1940, 400 ) Sleep(7000) ControlClick( "World of Warcraft", "", 0 , "right", 1, 1940, 400 ) Sleep(1000) Wend EndIf EndFunc I fixed it like this The script is not crashing anymore but it still dosn't do his job. WoW got no ControlID, the click dont get into the porgramm :-/ Share this post Link to post Share on other sites
Jos 2,213 Posted July 15, 2010 Im playing on a Privat server, so i am not bound to the EULA.We don't care as we cannot check.*click* SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Share this post Link to post Share on other sites