Sign in to follow this  
Followers 0
IamKJ

Image Search issues

6 posts in this topic

#1 ·  Posted

I have ran into some issues with image search.  Every time I run the script, it never finds the image in the browser, but if I open the image directly on the desktop, it'll find it no problem.

 

Why is this? Any way around it?

 Func ImageSearchFarm ()
     Local $picture = 'C:\Users\Jammmesss\Desktop\AutoIt\New folder\Icon.png'
     Local $x1 = 0
     Local $y1 = 0
     Do
         $result = _ImageSearch($picture,1,$x1,$y1,0,0)

         ConsoleWrite ($result)
     until $result = 1;
     if $result=1 Then
         MouseMove($x1,$y1,50)
     else
         MsgBox (0,'MSG','End')
EndIf
     EndFunc

 

Share this post


Link to post
Share on other sites



#2 ·  Posted

Can be closed.  Figured it out.

Share this post


Link to post
Share on other sites

#3 ·  Posted

First thing you must to include the library..  #include <ImageSearch.au3>

But i dont know why when i run your example show me.. Subscript used on non-accesible variable.. did you got this message too or not?

Share this post


Link to post
Share on other sites

#4 ·  Posted

No, I never received that message.

Share this post


Link to post
Share on other sites

#5 ·  Posted

On 3/27/2017 at 2:14 PM, IamKJ said:

Can be closed.  Figured it out.

It would be useful to the community to share how you solved it. 

Share this post


Link to post
Share on other sites

#6 ·  Posted

Just upped the tolerance a bit, somewhere between 50-100 is a good start, if there aren't too many images like the one you are searching for.

1 person likes this

Share this post


Link to post
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
Sign in to follow this  
Followers 0