← Back to team overview

sikuli-driver team mailing list archive

[Question #691072]: Read region value and return

 

New question #691072 on Sikuli:
https://answers.launchpad.net/sikuli/+question/691072

Hello,
Hope i can get an answer here.
I have a region where the count increases dynamically.
so i would like perform some actions based on the count,eg.if my region.value > 0 perform some print.However i see the below error.

[error] script [ testoutlook ] stopped with error in line 82
[error] AttributeError ( 'Region' object has no attribute 'count' )
[error] --- Traceback --- error source first
line: module ( function ) statement 
65: main (  blotter )     if reg.count > 0:
70: main (  itrachistory )     blotter()
71: main (  itrac )     itrachistory()
81: main (  main )     itrac()
82: main (  <module> )     main()
[error] --- Traceback --- end --------------

Code is 
def blotter():
                reg = Region(1590,950,320,59)
                count = 0
               
                wait(20)
                if reg.count > 0:
                    print("Blotter is loaded")
                else:
                    print("Blotter is not loaded")

            blotter()


-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.