Jump to content

Nested IFs for Image Search - (Locked)


Recommended Posts

If $decomposedisabledresult=1 Then   >>>>>> $decomposedisabledresult is an image
   MouseMove($X,$Y,5)
   MouseClick("Left")
   Sleep(1000)
   if $sortbuttonresult=1 Then         >>>> $allbuttonresult is an image
   MouseMove($X1,$Y1,5)
   MouseClick("Left")
   if $allpagesresult=1 Then               >>>> $allpageresult is an image
   MsgBox(0,"Result","Found!")
   EndIf
 EndIf
EndIf

 

So my problem is $decomposedisabledresult and $allbuttonresult is working but the last if statement for image search doesn't seem to work for me. any help? thanks!

Link to post
Share on other sites
  • Developers

is this really what you wanted:

If $decomposedisabledresult = 1 Then ;> >>>>> $decomposedisabledresult is an image
    MouseMove($X, $Y, 5)
    MouseClick("Left")
    Sleep(1000)
    If $sortbuttonresult = 1 Then ;> >>> $allbuttonresult is an image
        MouseMove($X1, $Y1, 5)
        MouseClick("Left")
        If $allpagesresult = 1 Then ;> >>> $allpageresult is an image
            MsgBox(0, "Result", "Found!")
        EndIf
    EndIf
EndIf

-or did you want this:

If $decomposedisabledresult = 1 Then ;> >>>>> $decomposedisabledresult is an image
    MouseMove($X, $Y, 5)
    MouseClick("Left")
    Sleep(1000)
    If $sortbuttonresult = 1 Then ;> >>> $allbuttonresult is an image
        MouseMove($X1, $Y1, 5)
        MouseClick("Left")
    EndIf
    If $allpagesresult = 1 Then ;> >>> $allpageresult is an image
        MsgBox(0, "Result", "Found!")
    EndIf
EndIf

Other than that your post is way to vague to be able to help as most of the script is missing so we have no clue what is going on.

Jos

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 post
Share on other sites
  • Developers

Due to last post:

Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no help and this thread will now be locked.

See you soon with a legitimate question I hope.

The Moderation team

Edited by Jos

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 post
Share on other sites
Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...