wazze Posted May 3, 2009 Posted May 3, 2009 (edited) Hello all! I have this script: If $v=2 Then do $coord = PixelSearch(0,0,1024,768,5210767) if not @error then $check = PixelGetColor($coord[0],$coord[1],0) If $check = 5210767 Then MouseMove($coord[0],$coord[1], 0) $v=2 EndIf until $v=2 EndIf When i want to run it, it says: "Until" statement with no matching "Do" statement.: until $v=2 how can i fix it? Edited May 3, 2009 by wazze
Mat Posted May 3, 2009 Posted May 3, 2009 (edited) If $v=2 Then do $coord = PixelSearch(0,0,1024,768,5210767) if not @error then $check = PixelGetColor($coord[0],$coord[1],0) If $check = 5210767 Then MouseMove($coord[0],$coord[1], 0) $v=2 EndIf until $v=2 EndIf badly nested statements is the problem. there cannot be an overlap!! Statement 1 Statement 2 /statement 2 /statement 1 try: If $v=2 Then do $coord = PixelSearch(0,0,1024,768,5210767) if not @error then $check = PixelGetColor($coord[0],$coord[1],0) If $check = 5210767 Then MouseMove($coord[0],$coord[1], 0) $v=2 EndIf EndIf Until $v = 2 EndIf MDiesel @AceGuy: I gave him the answer... Edited May 3, 2009 by mdiesel AutoIt Project Listing
Aceguy Posted May 3, 2009 Posted May 3, 2009 for EVERY if statement there must be an endif...???? hope this helps..... (without giving you the answer).. [u]My Projects.[/u]Launcher - not just for games & Apps (Mp3's & Network Files)Mp3 File RenamerMy File Backup UtilityFFXI - Realtime to Vana time Clock
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