Jump to content

If statments cancel out Do statment


Recommended Posts

do

sleep("100")

$var = PixelGetColor( 55 , 104 )

$ok = Pidelgetcolor( 541, 429)

If $ok = 15526360 then

mouseclick("left", 541, 429)

Else

send("1")

end if

until $var > 3238597

thats the code im working with. it returns the error until with no do statment. WTF i have a do statment! And if i take out the if statment it works fine. What am i doing wrong?

Link to comment
Share on other sites

  • Moderators

end if should be EndIf

Edit:

Pidelgetcolor should be PixelGetColor

Edit 2:

Until $var > 3238597

Shoul probably be Until $var <> 3238597

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.

Link to comment
Share on other sites

  • Developers

Understand you are in a hurry but no need to double post question in the BugReport forum... :P

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.
  :)

Link to comment
Share on other sites

end if

should be:

EndIf

with no spaces.

Do
    Sleep(100)
    If PixelGetColor(541, 429) = 0xECE9D8 Then
        MouseClick('', 541, 429)
    Else
        Send('1')
    EndIf
Until PixelGetColor(55, 104) > 0x316AC5
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...