Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

How to get imagesearch to check only the active window

$
0
0

    $x1=0
    $y1=0
    
    $result = _ImageSearch("xxx.bmp",1,$x1,$y1,100)
    if $result=1 Then
       
    ToolTip(" found! ", 400, 3)   
    MouseMove($x1,$y1,20)
    MouseClick("right",$x1,$y1)
    Sleep(1000)
    MouseMove($x1 +65, $y1 +7 ,20)
    Sleep(2000)
    
    
    
      Else
      ToolTip(" not! ", 400, 3)
      Sleep(500)
      
 EndIf

 

The problem i am having is it searches the whole computer screen, i want it to search only the active window. I'm not very experienced with autoit, can anyone tell me a simple way to change this to search only the active window?


Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>