Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[solved] scan image - finds once then fails forever
#1
Hi Gintaras,

Happy new year.

My "scan image" code works..once - but then fails forever afterwards.

Macro asdfdsf
Code:
Copy      Help
str ErrorStatus = "no"

int w=win("" "Mozilla*WindowClass" "" 0x4)
act w

RECT disqusshowallcommentsarea
SetRect &disqusshowallcommentsarea 175 150 260 975

spe 500

;repeat clicking "see more to show all comments per url" until err...then scroll..and repeat this.
rep 20
,scan "disqus - show all comments for url - firefox.bmp" w disqusshowallcommentsarea 1|2 100    
;,1 moves mouse to found image
;,2 gives error when unfound
;,100 allowed color difference

,err
,,'Q              ;; Page_Down
,,ErrorStatus = "yes"
,
,if ErrorStatus = "no"
,,lef
,ErrorStatus = "no"
#2
Because scan uses the rectangle for input and for output. Call SetRect before scan each time.
#3
Thanks, Gintaras. You da man!!!!!!! Big Grin


Forum Jump:


Users browsing this thread: 1 Guest(s)